in

ASP.NET Weblogs

This Blog

Syndication

Tags

No tags have been created or used yet.

Archives

Vishwas Lele's WebLog

Fleeting thoughts...

New FormsAuthentication & Cookie Persistence

Why are there multiple ways to set cookie peristence for ASP.NET Forms authentication? Each of the following related methods [1] allows you affect the cookie expiration period.

FormsAuthenticationTicket Constructor

FormsAuthentication.GetRedirectUrl Method
  

HttpCookie.Expires Property

[1] For example, consider the following sequence of related operations:

Create an authentication ticket (FormsAuthenticationTicket)

Derive a cookie from the ticket (FormsAuthentication.Encrypt)

Get the redirect URL (FormsAuthentication.GetRedirectUrl)

Set the cookie (Response.Cookies.Add(cookie) )

Comments

 

TrackBack said:

^_^,Pretty Good!
April 10, 2005 7:22 AM
 

TrackBack said:

^_~,pretty good!
April 17, 2005 5:33 AM

Leave a Comment

(required)  
(optional)
(required)  
Add