You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Debra Bartling <de...@berkeley.edu> on 2006/03/24 22:42:15 UTC
Problems with Tomcat and mod_proxy_ajp
I'm having problems with Tomcat 5.5.x, Apache 2.2.0, and
mod_proxy_ajp and resources that are protected with a
security-constraint. (This is after updating from Apache 2.0.54,
Tomcat 5.0.27, and mod_jk2, where the same configuration worked fine.)
The issues are different depending on the version of Tomcat.
In Tomcat 5.5.12, POST requests fail if a client does not have a
session established (for example, the session has timed out) and the
auth-method is FORM. The client is presented with the login form via
j_security_check and passed to the correct servlet, but there are no
request headers and no form data in the request. (My servlet tries to
log them -- nothing there.) This can be reproduced in Firefox and
Internet Explorer, so I don't think it's the browser. If I change the
configuration to BASIC authentication, it works correctly. If the
client has a session established, either method works OK. This
problem seems to be resolved in Tomcat 5.5.16.
BUT ...
In Tomcat 5.5.16, if the client tries to retrieve a PDF document
protected by a security-constraint and does not have a session
established, an error is reported. (Once logged in, there is no
problem.) If the auth-method is FORM, the document is retrieved but
Acrobat reports: "Acrobat could not open 'abc.pdf' because it is
either not a supported file type or because the file has been damaged
(for example, it was sent as an email attachment and wasn't correctly
decoded)." If the auth-method is BASIC, the login box is never
displayed at all. This problem did not occur with Tomcat 5.5.12
(using the same PDFs and browser).
Does anyone have a similar configuration working? Recommendations?
Debra Bartling
Earthquake Engineering Research Center
University of California, Berkeley
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Problems with Tomcat and mod_proxy_ajp
Posted by Debra Bartling <de...@berkeley.edu>.
At 08:03 PM 3/24/2006, Bill Barker wrote:
>Are you using the APR or the Java AJP/1.3 Connector? Whichever one it is,
>is it possible for you to test using the other one? Another test would be
>to see if it works with Apache 2.0.54+mod_jk(2).
I'm using the AJP/1.3 Connector.
More testing to do. But I had previously tried Apache 2.0.54 with JK2
and Tomcat 5.5.15 -- and had a different set of problems with form
login (and single sign on). When the login form appeared and I
entered the user name and password, the login form stayed on the
screen. If I reloaded the page in the browser, sometimes it would let
me in and sometimes it would give the message j_security_check not
available (then let me in after I reloaded the page again). And
single sign-on did not work across different webapps.
At this point, I assumed I had reached the end with JK2, and rather
than switch to mod_jk, I decided to go ahead and try mod_proxy_ajp
(and used Tomcat 5.5.16 since it was the latest version at that point).
Other specifics: Solaris 9, Java 1.4.2_03 with the JDK 1.4
compatibility package.
Debra Bartling
Earthquake Engineering Research Center
University of California, Berkeley
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Problems with Tomcat and mod_proxy_ajp
Posted by Bill Barker <wb...@wilshire.com>.
"Debra Bartling" <de...@berkeley.edu> wrote in message
news:7.0.1.0.2.20060324121852.02632ef8@berkeley.edu...
> I'm having problems with Tomcat 5.5.x, Apache 2.2.0, and mod_proxy_ajp and
> resources that are protected with a security-constraint. (This is after
> updating from Apache 2.0.54, Tomcat 5.0.27, and mod_jk2, where the same
> configuration worked fine.)
>
> The issues are different depending on the version of Tomcat.
>
> In Tomcat 5.5.12, POST requests fail if a client does not have a session
> established (for example, the session has timed out) and the auth-method
> is FORM. The client is presented with the login form via j_security_check
> and passed to the correct servlet, but there are no request headers and no
> form data in the request. (My servlet tries to log them -- nothing there.)
> This can be reproduced in Firefox and Internet Explorer, so I don't think
> it's the browser. If I change the configuration to BASIC authentication,
> it works correctly. If the client has a session established, either method
> works OK. This problem seems to be resolved in Tomcat 5.5.16.
>
Without looking at the changelog, I do believe that there were problems with
this in 5.5.12.
> BUT ...
>
> In Tomcat 5.5.16, if the client tries to retrieve a PDF document protected
> by a security-constraint and does not have a session established, an error
> is reported. (Once logged in, there is no problem.) If the auth-method is
> FORM, the document is retrieved but Acrobat reports: "Acrobat could not
> open 'abc.pdf' because it is either not a supported file type or because
> the file has been damaged (for example, it was sent as an email attachment
> and wasn't correctly decoded)." If the auth-method is BASIC, the login box
> is never displayed at all. This problem did not occur with Tomcat 5.5.12
> (using the same PDFs and browser).
>
Are you using the APR or the Java AJP/1.3 Connector? Whichever one it is,
is it possible for you to test using the other one? Another test would be
to see if it works with Apache 2.0.54+mod_jk(2).
Of course, if you can help to pin this down so it can be fixed, that would
be great. If you can't, well, I don't expect to be able to write a check
against your time ;-).
> Does anyone have a similar configuration working? Recommendations?
>
> Debra Bartling
> Earthquake Engineering Research Center
> University of California, Berkeley
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org