Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Completely Cookie  :)

Posted on 2006-11-17
3
Medium Priority
?
353 Views
Last Modified: 2006-11-18
I've been informed that:
cookies are like such:

VisitNumber  <-- cookie name
5                 <-- cooke value
localhost/     <-- domain/path that can access the cookie
1024            <-- cookie type
1522925568 <-- expire date/time
29894292     <-- expire date/time
1043531296 <-- modified date/time
29820999     <-- modified date/time
*  <-- end

cookie type:  im not really sure where these come from or what they mean other than if they were client created(javascript) vs server created(asp).  it also indicates whether the connection is secure by adding a value of one to the number.
client created:  1088, 1104, 1600
server created: 1024, 1536, 3584
a secure server created example would be 1024 + 1 = 1025

the expire and modified date and times are based on nano seconds.  the second field has a max number of 2^32 or 4,294,967,296 (i had to look that up).  the first field counts how many times the second field has maxed out.  so above, the expire second field has hit the max value 1,522,925,568 times.  
to start on the date we take that number and multiply by the max value:
1,522,925,568 * 4,294,967,296 = 6,540,915,508,802,224,128
then we add whats in the second field:
6,540,915,508,802,224,128 + 29,894,292 = 6,540,915,508,832,118,420
now you have the number of nanoseconds from january 1, 1601 12:00:00am (utc)



how can I get these values?
0
Comment
Question by:kevp75
3 Comments
 
LVL 9

Accepted Solution

by:
deathtospam earned 1800 total points
ID: 17965764
Here's some basic info on Cookies in ASP:

* MSDN - Setting Cookies in ASP using Response.Cookies: http://tinyurl.com/y64j46
* MSDN - Retrieving Cookies in ASP using Request.Cookies: http://tinyurl.com/y5tjrn
* General Tutorial - http://www.earthskater.net/devzone/asp/aspcookies.asp


I'm fairly certain that your ability to access cookies -- via ASP/VBScript, anyway -- is extremely limited, probably for security reasons.  All you can really do once a cookie is set, is display the names and values stored inside the cookie.  I don't believe you can access all of those properties you described above.


-= DeathToSpam =-
0
 
LVL 22

Assisted Solution

by:WMIF
WMIF earned 200 total points
ID: 17967121
i thought that you might have been able to get to the expire date, but according to that msdn article, nope.  oh well, at least you know what the cookie files mean now. :)
0
 
LVL 25

Author Comment

by:kevp75
ID: 17968053
thank you both.   I do understand how to set/retrieve cookies....my question was how to get the other stuff....but I see from those articles that those other keys are write-only....
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
I was asked about the differences between classic ASP and ASP.NET, so let me put them down here, for reference: Let's make the introductions... Classic ASP was launched by Microsoft in 1998 and dynamically generate web pages upon user interact…
This course is ideal for IT System Administrators working with VMware vSphere and its associated products in their company infrastructure. This course teaches you how to install and maintain this virtualization technology to store data, prevent vuln…
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
Suggested Courses
Course of the Month11 days, 5 hours left to enroll

885 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question