Re: session question

From: Patrick Y. Ng \(ms\) (patng@microsoft.com)
Date: 07/23/02


From: "Patrick Y. Ng \(ms\)" <patng@microsoft.com>
Date: Tue, 23 Jul 2002 10:19:49 -0700


You can only set the period before session expires due to inactivity. You
cannot set a "fixed" session expiry time.

But you can roll out your own "fixed" session expiry by calling
Session.Abandon at the right now.

--
Patrick Y. Ng
ASP.NET Developer
This posting is provided “AS IS” with no warranties, and confers no rights.
"San" <sanjay_nadimpalli@yahoo.com> wrote in message
news:OL7tdBfMCHA.1120@tkmsftngp10...
> Well Session.Timeout will change the timeout interval.  But I want to
change
> the session expiration time. How can I do that?
>
> Thanks
>
> San
>
> "Patrick Y. Ng (ms)" <patng@microsoft.com> wrote in message
> news:e9K8treMCHA.2380@tkmsftngp12...
> > You can set the value using Session.Timeout. (or set it thru config
file)
> >
> > --
> > Patrick Y. Ng
> > ASP.NET Developer
> > This posting is provided "AS IS" with no warranties, and confers no
> rights.
> >
> >
> > "San" <sanjay_nadimpalli@yahoo.com> wrote in message
> > news:utcrCQdMCHA.2664@tkmsftngp09...
> > > How is session expiration handled on server?  Does programmer have any
> > > control over it?  Can I programmatically "reset" the Session timer?
> > >
> > > Thanks
> > >
> > > San
> > > "Patrick Y. Ng (ms)" <patng@microsoft.com> wrote in message
> > > news:eq8hnHdMCHA.1976@tkmsftngp11...
> > > > (a) It's because no expiration date is set on the session id cookie
> > > > (b) Session expiry isn't implemented using the cookie expiry.  It's
> > > > implemented on the server side.  (Consider the case where cookieless
> is
> > > > used)  Session.Timeout gives you the expiry period in minutes.
> > > >
> > > > --
> > > > Patrick Y. Ng
> > > > ASP.NET Developer
> > > > This posting is provided "AS IS" with no warranties, and confers no
> > > rights.
> > > >
> > > >
> > > > "San" <sanjay_nadimpalli@yahoo.com> wrote in message
> > > > news:eRpWvpcMCHA.668@tkmsftngp09...
> > > > > I have the following two lines of code that get called on every
http
> > > > > request:
> > > > >
> > > > > HttpCookie cookie =
> > > > > HttpContext.Current.Request.Cookies["ASP.NET_SessionId"];
> > > > >
> > > > > Response.AppendToLog("Cookie expires on date:" + cookie.Expires);
> > > > >
> > > > > The expiration time on cookie ASP.NET_SessionId is always January
1,
> > > 0001,
> > > > > 12 AM.  Two things:
> > > > >
> > > > > (a)  Why is it initialized to Jan 1, 2001 12 AM?
> > > > >
> > > > > (b) Shouldnt the cookie expiration change whenever the user makes
a
> > > > request
> > > > > (within the 20 minute interval, assuming session timeout is set to
> 20
> > > > > minutes).
> > > > >
> > > > > Thanks
> > > > >
> > > > > San
> > > > >
> > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>


Relevant Pages

  • RE: [PHP] Dealing with session expiry
    ... > the problem that I having is that session expiry will cause that site to ... > I notice sites using login detect expiry automatically and refrest the pages ... > + session, I just don't quite know how to apprach it. ... setting that will stay across browsers being closed, use a proper cookie, not ...
    (php.general)
  • Re: Regarding Session reset
    ... The best you can do is use session expiry times on the server. ... You can *try* and use an onunload event handler in the page to trigger a ...
    (comp.lang.php)
  • Infinite loop problem
    ... We are facing an issue in which we our session expiry page is being ... fetched in an infinite loop. ... Whenever the session expires, the session ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: GetProcessWindowStation() and terminal services
    ... new process will be launched in the same session of the caller. ... This posting is provided "AS IS" with no warranties, and confers no rights. ... > WindowStatioin the process is being launched into or the window does not ... > how to get a handle to the WindowStation for the session I will launch ...
    (microsoft.public.platformsdk.security)
  • Re: Error connecting to existing session
    ... This posting is provided "AS IS" with no warranties, and confers no rights. ... > login session was created from the console or remotely, ... > login under an alternative admin account and kill the initial session ... Then login as that user again via remote desktop. ...
    (microsoft.public.windowsxp.work_remotely)