Solved

cookie expire

Posted on 2000-05-07
1
160 Views
Last Modified: 2010-03-05
do any one know how long does the cookie of experts-exchange.com last?

I would like to set cookie like EE, but i don't know how long it should last.

Thanks.
0
Comment
Question by:bighuen
1 Comment
 
LVL 16

Accepted Solution

by:
maneshr earned 10 total points
ID: 2788481
"do any one know how long does the cookie of experts-exchange.com last? "

you can find that out for yourself. if you are using NS look at your cookies.txt file. in it you will find an entry that looks something like...

..experts-exchange.com      TRUE      /      FALSE      1900195130      login      16739:hsWRAr0dF60w2k

Each line in the cookies.txt file represents a single piece of stored information. A tab is inserted between each of  the fields.

 From left-to-right, here is what each field represents:

 domain - The domain that created AND that can read the variable.
 flag - A TRUE/FALSE value indicating if all machines within a given domain can access the
 variable. This value is set automatically by the browser, depending on the value you set
 for domain.
 path - The path within the domain that the variable is valid for.
 secure - A TRUE/FALSE value indicating if a secure connection with the domain is needed
 to access the variable.
 expiration - The UNIX time that the variable will expire on. UNIX time is defined as the number of seconds since Jan 1, 1970 00:00:00 GMT.
 name - The name of the variable.
 value - The value of the variable.


So as you can see in the cookie above the expiration is set to 1900195130 seconds since  Jan 1, 1970 00:00:00 GMT.
==========================================

here is a small PERL/CGI program using which you can set your own cookie.

the cookie expires on mon 27th Nov.

===my_cookie.pl

#!/usr/local/bin/perl

print "Set-Cookie: back=yes; path=/; expires:Mon, 27-Nov-2000 23:00:59 GMT\n";
print "Content-type: text/html\n\n";
  print qq{
  <B>Cookie set successfully!!/B>
 };


in order to check if the cookie is set, enable "Warn before cookie is set" option in your browser.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

On Microsoft Windows, if  when you click or type the name of a .pl file, you get an error "is not recognized as an internal or external command, operable program or batch file", then this means you do not have the .pl file extension associated with …
I have been pestered over the years to produce and distribute regular data extracts, and often the request have explicitly requested the data be emailed as an Excel attachement; specifically Excel, as it appears: CSV files confuse (no Red or Green h…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

707 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

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now