Web Servers
--
Questions
--
Followers
Top Experts
<CFAPPLICATION
NAME="myApp"
CLIENTMANAGEMENT="yes"
SESSIONMANAGEMENT="yes"
CLIENTSTORAGE="cookie"
SETCLIENTCOOKIES="yes"
SETDOMAINCOOKIES="yes"
SESSIONTIMEOUT=#createtime
Every time a user clicks on a different page, they receive a new CFID and a new CFTOKEN value. So every page is seen as a different user and none of the client tracking mechanisms work. Can anyone explain why the CFID and CFTOKEN are changing on me?
Zero AI Policy
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
I am too small to advise I will just try.
They change for everybody and that is how it works for security.
you may change your mechanism to detect the user.
may be using the session values... you may store the username or userid in the session and detect using it.
Regards,
---Pinal
Which browser are you using and what is your security configuration pertaining to cookies?






EARN REWARDS FOR ASKING, ANSWERING, AND MORE.
Earn free swag for participating on the platform.
None of the computers are set to deny cookies.
Can you post the application.cfm code?

Get a FREE t-shirt when you ask your first question.
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
<CFERROR TYPE="request" TEMPLATE="errorrequest.cfm
<CFERROR TYPE="exception" TEMPLATE="errorexception.c
- create a new directory
- in it create application.cfm as follows:
--------------------------
<CFAPPLICATION
NAME="myApp"
CLIENTMANAGEMENT="yes"
SESSIONMANAGEMENT="yes"
CLIENTSTORAGE="cookie"
SETCLIENTCOOKIES="yes"
SETDOMAINCOOKIES="yes"
SESSIONTIMEOUT=#createtime
--------------------------
- create only one file as follows:
--------------------------
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Strict//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
</head>
<body>
Client:
<cfdump var="#client#" expand="yes" label="client">
<hr>
Session:
<cfdump var="#session#" expand="yes" label="session">
</body>
</html>
--------------------------
Does reloading of the page cause CFID and CFTOKEN to change?
Can you post the code that is in the <cfapplication> tag - I am sure the answer is related to the settings.






EARN REWARDS FOR ASKING, ANSWERING, AND MORE.
Earn free swag for participating on the platform.
==========================
<CFERROR TYPE="request" TEMPLATE="errorrequest.cfm
<CFERROR TYPE="exception" TEMPLATE="errorexception.c
<CFAPPLICATION
NAME="myApp"
CLIENTMANAGEMENT="yes"
SESSIONMANAGEMENT="yes"
CLIENTSTORAGE="cookie"
SETCLIENTCOOKIES="yes"
SETDOMAINCOOKIES="yes"
SESSIONTIMEOUT=#createtime
==========================
I'm trying the test file that marcin_kom asked about above right now. I'll post results as soon as I'm done.
Here's the summary:
* Client.CFID stays the same.
* Client.CFTOKEN stays the same.
* Client.URLToken changes every page request.
* Session.CFID changes every page request.
* Session.CFTOKEN changes every page request.
* Session.URLToken changes every page request.
It seams that there is a bizzar way your server is handling cookies. Only half of the cookies get set in the browser when viewing your page (i.e. two cookies), while when I put the page up on my server four cookies get set. There is a difference also between the two servers in what the response header contains.
Compare the difference. You can find the same test on my server at http://www.clubpolonia.com/_ee_/Q_21468895/test.cfm
Here is your header:
--------------------------
Connection: close
Date: Wed, 29 Jun 2005 06:22:40 GMT
Content-Type: text/html; charset=UTF-8
Server: Microsoft-IIS/6.0
Set-Cookie: CFID=299331;domain=.com;ex
CFTOKEN=45022843;domain=.c
CFCLIENT_MYAPP=;expires=Fr
CFGLOBALS=urltoken%3DCFID%
Content-Encoding: gzip
Vary: Accept-Encoding
Transfer-Encoding: chunked
200 OK
--------------------------
and here is mine:
--------------------------
Connection: close
Date: Wed, 29 Jun 2005 06:30:48 GMT
Server: Microsoft-IIS/6.0
X-Powered-By: ASP.NET
Set-Cookie: CFCLIENT_MYAPP=;expires=Fr
CFGLOBALS=urltoken%3DCFID%
Content-Type: text/html; charset=UTF-8
200
--------------------------
Doing some more investigation I think my server starts by setting two cookies using first response header (not shown here), than redirect the browser to reload the page, and sets the remaining two cookies using the response header shown here.
Your server attempts to set all four cookies in a single header, but something about the way it does it results in the cookie being ignored by a browser. I am only guessing that this may have to do with "domain=.com" portion of the 'Set-Cookie' directive.
Do you have access to your server's configuration, both ColdFusion and IIS?
Marcin
P.S. FireFox with the Web Developer Toolbar Extension is an awesome tool for getting at this type of information (in case you are not using it already)

Get a FREE t-shirt when you ask your first question.
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.






EARN REWARDS FOR ASKING, ANSWERING, AND MORE.
Earn free swag for participating on the platform.
If you want to dig deeper into this I'll be here to lend you a hand. However, given the current situation you could always use Client.CFID and Client.CFTOKEN.
If you require URLTOKEN, you could always generate that manually from CFID and CFTOKEN as 'CFID='&Client.CFID&'&CFTO
Marcin
Thanks for the help!
Cheers,
Marcin

Get a FREE t-shirt when you ask your first question.
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
I'm running Windows 2003 Web Ed.
CFMX 7.01
Several development sites.
One site would always create new session variables for every reload of the page.
I found out that if I was using an address that included an underscore "_" in the URL the session would be recreated with each reload.
For example, when I had the address as:
client_dev.domain.com - causes the session to be recreated each reload unless you force it with URLTOKEN vars.
However,
clientdev.domain.com - will keep the same session values for every reload.
I don't know if this is related to your problems. I think that I will avoid using underscores in domain names.
Incidentally, this problem only appeared in IE. Firefox did not exhibit this problem.
Web Servers
--
Questions
--
Followers
Top Experts
A web server refers to the software that helps to deliver web content that can be accessed either through the Internet or through an intranet. The primary function of a web server is to store, process and deliver web pages to clients. The communication between client and server takes place using the Hypertext Transfer Protocol (HTTP). The most common use of web servers is to host websites, but there are other uses such as gaming, data storage, running enterprise applications, handling email, FTP, etc.