RE: RedirectFromLoginPage persistent cookie expiration
From: jester (jester_at_discussions.microsoft.com)
Date: 11/30/04
- Next message: Scott Allen: "Re: dynamically load DLL exception when calling Activator.CreateInstance(type, object[])"
- Previous message: KSK: "How to pass Windows login credentials to Active Directory"
- In reply to: John Paul. A: "RE: RedirectFromLoginPage persistent cookie expiration"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Mon, 29 Nov 2004 16:55:09 -0800
But what would be the default cookie expiration if I don't set it explicitly?
"John Paul. A" wrote:
> Hi jester,
> Please ignore my previous reply, becoz my reply to DPAPI has come here.
>
> Regarding the RedirectFromLoginPage - persistent cookie, you can control the
> expiration date, it is also a good practice too..
> Here how you can do?
>
> If persistentCookie And expirationDays > 0 Then
> ' Get a reference to the cookie just created.
> Dim cookie As HttpCookie = Response.Cookies _
> (FormsAuthentication.FormsCookieName)
> ' Set its expiration date.
> cookie.Expires = Now.AddDays(expirationDays)
> ' Ensure the cookie can travel only over https.
> 'cookie.Secure = True
> End If
>
> Rgds,
> John Paul. A
>
>
> "jester" wrote:
>
> >
> > Passing true for the second parameter of RedirectFromLoginPage creates a
> > persistent cookie. When does this cookie expire?
> >
- Next message: Scott Allen: "Re: dynamically load DLL exception when calling Activator.CreateInstance(type, object[])"
- Previous message: KSK: "How to pass Windows login credentials to Active Directory"
- In reply to: John Paul. A: "RE: RedirectFromLoginPage persistent cookie expiration"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|
|