tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <>
Subject Re: mod_jk: confirming JKStripSession setting
Date Tue, 06 Apr 2010 14:41:29 GMT
Hash: SHA1


(Forgot to mention I'm using mod_jk 1.2.30 compiled locally)

On 4/3/2010 12:33 PM, Rainer Jung wrote:
> On 01.04.2010 00:21, Christopher Schultz wrote:
>> Except that I have JKStripSession enabled -- at least, I think I do.
> It should respect virtual hosts, one thing that could go wrong.
> JkStripSession actually takes an optional second argument, the start of
> what has to be stripped (by default ";jsessionid").

I have JKStripSession declared inside of the VirtualHost being used in
this case. It goes something like this:

<VirtualHost *:80>

  Include /path/to/custom/*.conf

  # mod_jk options
  JkStripSession On


  Alias /context /path/to/static/files
  JkMount /context/*.jsp worker1

So, that looks good to me so far, but it's still behaving like it's not
stripping the session (that is, my images are broken when ;jsessionid is
a part of the URL).

I can confirm that /path/to/static/files/images/help_widget.gif does in
fact exist: when the ;jsessionid is not part of the URL, the image loads
as expected.

> Debug should show (Apache):
> "removing session identifier [%s] for non servlet url [%s]"

Aah, I'm not sure if I bothered to actually make a request with DEBUG
turned on. I'll check that...

Okay, I can see it:

[Tue Apr 06 14:34:58.061 2010] [7178:3056749456] [debug]
jk_map_to_storage::mod_jk.c (3609): no match for
[Tue Apr 06 14:34:58.061 2010] [7178:3056749456] [debug]
jk_map_to_storage::mod_jk.c (3619): removing session identifier
for non servlet url

Has it removed too much of the URL? It looks like it's chosen
";jsessionid=4C1E21B0202F52187EB8DF1EE9E1CF85/images/help_widget.gif" as
the session identifier. Am I reading that wrong?

> each time something is actually removed in case Apache has internally
> set r->uri. If it has only set r->filename, nothing will be logged :)
> Could it have to do with something else like PHP involved? Any other
> tricks to map the image URL?

Possible, but unlikely: we're not using PHP on this site, and no other
manipulations are being done (or, no others are intended): it's just a
static .gif file on the disk.

What next?

- -chris
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla -


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message