Re: URL refresh in passive mode
"Scott Tully" <[email protected]>
| Newsgroups | gmane.network.nocat |
|---|---|
| Message-ID | <[email protected]> |
Sameer - ----- Original Message ----- From: "Sameer Verma" <[email protected]> To: <[email protected]> Sent: Friday, October 01, 2004 3:47 AM Subject: Re: [NoCat] URL refresh in passive mode > Answering my own questions... > > Sameer Verma wrote: > > > When I use one of my gateways in passive mode, the popup displays the > > following: > > 1) Initial popup has a URL refresh to the auth server with a waiting > > time of 450 seconds (my gateway has a loginTimeout of 600 seconds). > > 2) After the first refresh, the popup source shows a URL refresh as > > > > <meta http-equiv="Refresh" content="5; > > URL=http://192.168.89.1:5280/?ticket=<really-long-ticket-string> > > > > 3)The setTimeout javascript function still exists, where it resubmits > > the RenewalForm every 450 seconds. > > > > My questions: > > 1) Is the popup being refreshed from the gateway every 5 seconds? I > > don't seem to find that traffic in ethereal. > > I do see traffic, except it is a HTTP 204 response coming back from the > gateway, which simply means "No change in the document view". See > http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.5 > > > 2) Why 5 seconds? Why not 450 seconds? > > Once again, why every 5 seconds? Why should the popup talk to the > gateway every 5 seconds?What's so magical about 5 seconds? I learned allot more about how this works when i re-wrote the Authserver in JAVA. The answers: That's a good little buffer. It doesn't. Nothing. When the 204 is returned to the browser it will not make that request again.... The browser is actually not on the page with the 5 second meta refresh... it's in a limbo state. the request was made and the browser tried to retrieve a page from the gateway... so it went there and got told be the gateway "no content".... the meta refresh does not continue to refresh every five seconds because it's no longer part of the header information. it was lost when the request was made to the gateway. When the renew form is resubmitted every 450 seconds it resets the header which contains the meta refresh that sends the ticket to the gateway ASAP, or 5 seconds, to notify the gateway that the user is still there... so you really get 455 seconds between renews.... Hope that demystifies the process a little.... Scott > > > > > 3) If the page reloads every 5 seconds, why have the setTimeout function? > > > I figured this one out. Since the URL refresh is basically returned with > a HTTP 204, we use the setTimeout to submit the RenewalForm to get a new > auth token every 450 seconds. > > > Any insight would be great. > > Talking to myself is no problem. The problem begins when I start > answering my own questions :-) > > > -- > > Sameer > > -- > Sameer > > _______________________________________________ > NoCat mailing list > [email protected] > http://lists.nocat.net/mailman/listinfo/nocat > >