Fog Creek Software
Discussion Board




Login cookie shouldn't be tied to an IP address

I've noticed that the login cookie (when you check the box "Remember me at this computer") is tied to my IP address.

This is frustrating on a notebook computer as I frequently switch between being docked and two different 802.11 networks. Each time I change I have to re-login to FogBUGZ.

It would sure be convenient if the login cookie wasn't tied to my IP address.

Nathan Silva
Tuesday, January 28, 2003

This one's hit me too.  I recently upgraded my router to a Nexland pro800turbo which load balances between two broadband connections.  Let's just say that it's no fun using fogbugz when I have to log in every other time.

Please, don't make the cookie ip-dependent.

Jason
Wednesday, February 26, 2003

Uh, would it be too much to ask someone for at least a response?  This "feature" is really starting to annoy the h-e-double-hockey sticks out of me.

Jason
Thursday, February 27, 2003

Oh, the heck with it.

If you are having a problem with this, edit "default.asp"

On or about line 96, you'll see two lines:

' PRE PHASE
'

Add the following code after those lines:

        ' Added by to prevent problems with logging in from different IP Addresses
        Dim cmd : Set cmd = Server.CreateObject("ADODB.Command")
        Set cmd.ActiveConnection = dbGlobal
        cmd.CommandText = "update tokens set sIPAddress = " & chr(39) &_
            request.serverVariables("REMOTE_ADDR") & chr(39) &_
            " where sIPAddress <> " & chr(39) & request.serverVariables("REMOTE_ADDR") & chr(39) &_
            " and fbToken = " & chr(39) & request.cookies("fbtoken") & chr(39)
        dim rs : Set rs = cmd.Execute(,,adcmdText)
        Set cmd = Nothing



That will automatically change your ip address in the tokens table if it's different.

Jason
Friday, February 28, 2003

Thanks Jason, that works. I hope the FogBUGZ people fix this "for real" in the next version. I think our situation -- multiple IP addresses -- is going to become more common.

Nathan Silva
Monday, March 03, 2003

*  Recent Topics

*  Fog Creek Home