RedirectFromLoginPage persistent cookie expiration

Ask a Question related to ASP.NET Security, Design and Development.

  1. #1

    Default RedirectFromLoginPage persistent cookie expiration


    Passing true for the second parameter of RedirectFromLoginPage creates a
    persistent cookie. When does this cookie expire?

    jester Guest

  2. Similar Questions and Discussions

    1. Persistent Shared Object not being persistent
      hi my fms app maintains a persistent shared object to keep track of daily highscores, however whenever the app is reloaded or restarted all the...
    2. Cookie Expiration Date
      :confused; Can anyone help me figure out how to change the date that my coldfusion server sets for expiration on client housed cookies? I have run...
    3. Cookies set one time, I delete cookie, cookie is never set again!
      I am having this problem: My PHP script will set a cookie, it's there in my /Cookies folder. I delete the cookie (I have to for testing purposes,...
    4. Expiration time of a cookie
      What is the longest expiration time of a cookie? Thanks ________________________________________________________________ The best thing to hit...
    5. Cookie Expiration
      Is there a way to write a cookie to the browser, then redirect.... If I do the following, the cookie is not written. Dim cookie As New...
  3. #2

    Default RE: RedirectFromLoginPage persistent cookie expiration

    Hi jester,
    Please check your config file. If everything goes right, please check the
    security settings for the dll.
    Rgds,
    John Paul. A

    "jester" wrote:
    >
    > Passing true for the second parameter of RedirectFromLoginPage creates a
    > persistent cookie. When does this cookie expire?
    >
    John Paul. A Guest

  4. #3

    Default RE: RedirectFromLoginPage persistent cookie expiration

    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?
    >
    John Paul. A Guest

  5. #4

    Default RE: RedirectFromLoginPage persistent cookie expiration


    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?
    > >
    jester Guest

  6. #5

    Default RE: RedirectFromLoginPage persistent cookie expiration

    Dear jester,
    The default time-out limit is 20 minutes.
    Please see the Microsoft documentation "Configuring ASP.NET Applications to
    Use the Appropriate Session State"

    [url]http://www.microsoft.com/resources/documentation/WindowsServ/2003/all/deployguide/en-us/Default.asp?url=/resources/documentation/WindowsServ/2003/all/deployguide/en-us/iisdg_net_mshe.asp[/url]

    Sorry.. The URL is bit long...

    Rgds,
    John Paul. A

    "jester" wrote:
    >
    > 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?
    > > >
    John Paul. A Guest

  7. #6

    Default RE: RedirectFromLoginPage persistent cookie expiration


    Thanks, John Paul.

    "John Paul. A" wrote:
    > Dear jester,
    > The default time-out limit is 20 minutes.
    > Please see the Microsoft documentation "Configuring ASP.NET Applications to
    > Use the Appropriate Session State"
    >
    > [url]http://www.microsoft.com/resources/documentation/WindowsServ/2003/all/deployguide/en-us/Default.asp?url=/resources/documentation/WindowsServ/2003/all/deployguide/en-us/iisdg_net_mshe.asp[/url]
    >
    > Sorry.. The URL is bit long...
    >
    > Rgds,
    > John Paul. A
    >
    > "jester" wrote:
    >
    > >
    > > 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?
    > > > >
    jester Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139