If you wish to see struts' cookies in the browser - then the easiest way is
to use Mozilla (http://www.mozilla.org/). After browsing your struts app
then use the following mechanism to find the cookie that is being used:
Moz:
Edit... Preferences...
Privacy & Security / Cookies
Select "Manage Stored Cookies"
Look for the site, e.g. "localhost", "www.domain.tld"
There should be a cookie named "JSESSIONID" - click on it to see the session
id
More info on "per session" cookies
--
IE does not seem to save the cookie to disk as the cookie is a "per session"
cookie. A "per session" cookie is a cookie that is only valid for the
current session - distinguished from a non-"per session" cookie by the fact
a "per session" cookie does not have an "EXPIRES" attribute.
See the following output from nc
(http://www.atstake.com/research/tools/network_utilities/) that makes this
clearer:
1) Output from a site with a "per session" cookie:
--
X:\>nc 127.0.0.1 8081
GET /index.jsp HTTP/1.0
HTTP/1.1 200 OK
Content-Type: text/html;ISO-8859-1
Connection: close
Date: Wed, 06 Aug 2003 12:04:34 GMT
Server: Apache Tomcat/4.0.6 (HTTP/1.1 Connector)
Set-Cookie: JSESSIONID=5BF64BD681D362A1962D81AF7A3B4362;Path=/
2) Output from a site with a NON-"per session" cookie:
--
X:\>nc java.sun.com 8081
GET / HTTP/1.0
HTTP/1.1 200 OK
Server: Netscape-Enterprise/6.0
Date: Sat, 16 Aug 2003 15:09:16 GMT
Content-type: text/html
Cache-control: no-cache="set-cookie"
Set-Cookie: SUN_ID=12.34.56.78:1615:1061046556:19410; EXPIRES=Wednesday,
31-Dec-2025 23:59:59 GMT; DOMAIN=.sun.com; PATH=/
Note the addition of the "EXPIRES" information in the second example that
will indicate to the browser that this is _not_ a "per session" cookie. The
latter will be visible in the IE; the former will not. Mozilla will display
both in the "Manage Stored Cookies" window.
Hue.
> -Original Message-
> From: Adolfo Miguelez [mailto:[EMAIL PROTECTED]
> Sent: 16 August 2003 14:53
> To: [EMAIL PROTECTED]
> Subject: Re: where is JSESSIONID?
>
>
> I have also wondered the same question many times. I assume in browser's
> memory you mean. Good.
>
> Is there any way to access it from the client code, javascript or related
> stuff?
>
> I my understanding cookies are stored in browser's machine hard disk. Is
> this cookie for session an exception? I have seem many cookies in the
> temporary files directory of the browser installation.
>
> More info would be appreciated,
>
> Adolfo.
>
> >From: Koni Roth <[EMAIL PROTECTED]>
> >Reply-To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
> >To: Struts Users Mailing List <[EMAIL PROTECTED]>
> >Subject: Re: where is JSESSIONID?
> >Date: Sat, 16 Aug 2003 04:20:37 +0200
> >
> >If the browser does not accept cookies it is stored in the URL. If the
> >browser accepts cookies it is stored in the memory (session).
> >Koni
> >
> >Billy Ng wrote:
> >>Hi folks;
> >>
> >>Anybody knows where is the JSESSIONID cookie is? I search the whole
> >>Cookies folder, I can't find it.
> >>
> >>Billy Ng
> >>
> >>
> >>This mailbox protected from junk email by Matador
> >>from MailFrontier, Inc. http://info.mailfrontier.com
> >>
> >
> >--
> >Konrad Roth,
> > - http://www.rothweb.ch
> > - http://www.rothconsulting.com
> > - Jump and the earth will rise to meet you!
> >
> >
> >-
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >
>
> _
> The new MSN 8: smart spam protection and 2 months FREE*
> http://join.msn.com/?page=features/junkmail
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
> ---
> Incoming mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.510 / Virus Database: 307 - Release Date: 14/08/2003
>
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.510 / Virus Database: 307 - Release Date: 14/08/2003
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]