Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Session Reseting

Status
Not open for further replies.

carpediem79

Technical User
Aug 2, 2005
52
US
I have a web page which many users are able to use without incident. There is one user who is on a specific computer who can log in and start a session. However when he tries to go to the next page, it kicks him back to the login page as though his session has been reset/closed. The CFID and CFTOKEN, which should remain the same, are incremented in the URL when he goes to the next page. He can login on other PC's just fine without this occuring.

Any help on how/why this is happening and how to fix it would be greatly appreciated.

Thanks all in advance.
 
Make sure cookies are enabled on that particular PC.


Hope This Helps!

ECAR
ECAR Technologies

"My work is a game, a very serious game." - M.C. Escher
 
I think ECAR is right - this almost has to be cookie related. Try a different browser on that machine and see what happens.

Cheers,

Bluetone
 
I am having the same issue with a handful of users. I had one helpful user installed FireFox (most current version), and she still has the same problem. I also create 3 test pages to try and see what is going on.

1st test page:
Creates a cookie and a session variable using the following:
<CFCOOKIE name="test" value="1">
<CFSET session.test = true>
then, on the same page, it does an IsDefine for the fresh cookie and session variable.
[COLOR=red yellow]Result on user's browser: both are defined.[/color]

2nd test page (which she links to from the first test page):
simply does an IsDefine on the test cookie and test session (created on the first page).
[COLOR=red yellow]Result on user's browser: cookie IS defined, session IS NOT[/color]

3rd test page:
simply expires the cookie and clears the session variables (<cfset StructClear(Session)>).

So, I don't think this is a cookie issue. She has added my site (in IE7) to her "Trusted" sites list, and we made sure her browser was set up to accept cookies.

Thoughts? I'd really like to get this resolved. Until this most recent user, I had just been asking folks to install Firefox. Guess I can't ask them to do that any more...at least not for the purposes of working around this issue [wink] .


 
I have run into the a couple of times. I should have read your original post better. there has been some speculation that one of the tags (maybe cftransaction - I don't remember) kills the session variables - on occasion. In both cases I resorted to temporarily storing the session variables in a cookie - which I could do as both were on a controlled enviroment intranet. This approach won't work on a public site as some users disable cookies.


Then on the next page if the session variable is undefined you use the cookie instead.

Well - cancel all that. You are having issues with specific machines so I suspect something else is the issue. However, you might still be able to incorporate the same kind of work around.

Cheers,

Bluetone
 
Ok....I have a little more info that I am hoping with spark an idea with someone. Seems the domain name has something to do with it. If I have the user access the site via a slightly different domain name, everything works just fine. So, for example:

test.mydomain.com - session timeout problem occurs
- session timeout works perfectly

Both point to the same physical directory.

Any ideas?
 
Are both sites on the same server? Are both using the same CF Server?

Cheers,

Bluetone
 
Yep. Both on same server, same instance of ColdFusion.

Could the browser have cached something that is corrupting the session? I guess that can't be, since 2 different types of browser on the same PC had the same problem.

Do IE and FireFox share cookies? I know I showed above that cookies were set and maintained properly, but maybe the part of the cookie used to maintain sessions is corrupt?

Just thinking out loud here....
 
I'm not sure if this will fix it but we had problems with sessions being deleted with domains like you talk about. Add setDomainCookies="Yes" to your cfapplication tag and see if that fixes it

Hope this helps!

Tony
 
Roshec, sorry to say I have not found a solution yet. I have noticed that any change in the domain name (be-it secure or not) seems to be a work-around for the handful of users that encounter this issue. I will be upgrading to CFMX7 next week (currently at 6.1), and I am hopeful this will somehow fix it. But I have my doubts. What version of CF are you using?
 
That's a real bummer. We're using an ancient version of coldfusion server (5). But looks like its still a problem with 6.1 'coz that's what you have. What puzzles me more is that only some users have the issue and others don't. I don't think we had this issue with the orignal URL (
Please let me know how you go with CFMX7

thanks
 
Will do. Was hoping to do the upgrade this week, but it will have to be next. Might then take a few days to get a user with the issue to try it out.
 
Well, my upgrade to CFMX 7 went very poorly due to a known issue with upgrading on a Windows 2003 SP-1 server. This isn't the right thread to discuss the issue (though I'll at least share with you to kb article Adobe has posted on it...which hasn't helped so far) -
That said, I am still running 6.1 (barely), and may try an upgrade again tonight. If it doesn't happen tonight, it will likely be a couple of weeks.

Nights like last night make me wish I mowed lawns for a living.
 
I don't know about mowing lawns (I've got a sloping block and that's bad enough). But I completely understand. We do have MX7 but await your success.

cheers
 
Well, it didn't happen last night. I am still gathering information on how I can make the upgrade work with just one more attempt. I learned there is free Adobe support available for CF installations (if you paid for the license). Anywho, since it didn't happen last night, it will probably be a few more weeks. I'll keep you posted.
 
I too am getting reports of this exact same Coldfusion session resetting issue, has anyone found a fix for this.

Thanks, Peter
 
One of these days I am going to be upgrading my CF server to version 7 to see if that fixes the problem. My need for upgrading has a lower priority than other things, so I haven't had the chance to do it.

Peter, what version of CF are you using?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top