Huggle Proxy Hack
A hack of Huggle Version (0.7.10) to allow use behind a proxy

-- July 02, 2008 --

I made a few changes to allow Huggle to default to Internet Explorer's proxy settings.  You can still specify the settings yourself, but if you leave them blank Huggle will use the same proxy and credentials as IE.  Manually entered proxy settings are now stored in Huggle's config file.  Finally, I fixed the exception that was being thrown at program close.

Binary:  huggleProxyVia0701_v001.exe



-- June 25, 2008 --

Here's the source and executable of my current hack of  Huggle.

Binary:  huggleProxy001Via0710.exe


Most of the changes I've made can be found in login.vb and the login form, but also had to add Client.Proxy = Login.getProxy() for every client created.

The two procedures/functions I created in Login.vb are:

    Public Sub ConfigureProxy(
            ByVal Address As String,
            ByVal Port As String, 
ByVal Username As String, 
            ByVal Password As String, 
            ByVal Domain As String)
        Login.ProxyPassword = Password
        Login.ProxyUser = Username
        Login.ProxyAddress = Address
        Login.ProxyDomain = Domain

        If (Login.ProxyAddress = "") Then
            Login.ProxyIsNeeded = False
            Login.ProxyIsNeeded = True
        End If

        Dim temp As String
        temp = Address

        If (temp = "") Then
            Login.ProxyPort = 80
            Login.ProxyPort = CInt(Port)
        End If
    End Sub


    Public Function getProxy() As WebProxy
        If (Login.ProxyIsNeeded) Then
            Dim proxyString As String
            proxyString = "http://" & Login.ProxyAddress & ":"
                           & Login.ProxyPort & "/"
            Dim wp As New WebProxy(proxyString, True)
            wp.Credentials = New NetworkCredential(
            wp.UseDefaultCredentials = True
            Return wp
            Return New WebProxy
        End If
    End Function

It's not pretty (I'm more of a Java guy), but it seems to work.  The input boxes look hideous, and should probably be hidden unless the user absolutely needs them. At present the biggest problem I can forsee is that there are probably situations in which a field left blank (say, the user's domain) might throw an exception.  I have no easy way of testing those cases at the moment.  All I can say for sure is that it works fine behind my proxy, and also works fine on my school's network.

 ~~~~ Bartledan

Note: Upon program close the .NET framework complains about an unhandled exception.  I'm not exactly certain what the problem is yet, but I'm working on it.

Huggle was created by Gurch.  The version found on this page is an untested hack of an otherwise beautiful piece of software.