Cookies Expiration Date... what timezone?

When setting the expiration date for a cookie, I assume the user’s local timezone is being used.

In the rare occasion of Daylight Saving rollover, it might happen that the clock is set back by an hour it might raise some issues.

Also, my server apps always use UTC time. It might happen that the expiration date is set to a date prior to the user’s system time. And it might happen that the cookie expires before I plan it to be expired.

What about collecting the user current GMT time (UTC) and calculate the difference against yours (time offset) and sending him a calculated “expires” GMT instead of guessing timezones.

If you’re using Session.Cookies.Set, you should pass in a GMT date for the expiration because the string we send along assumes that.

So, the “Cookie Jar” of the user’s browser uses the GMT date to determine if the cookie needs to be removed?

Yes.