You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Ar...@csiro.au on 2007/06/29 03:17:10 UTC

Tomcat authentication custom realm digest="md5" ignored

Hi, 

 

I have this setup working on my Windows development computer under
Tomcat 5.5. Everything works fine. I get a hash value from Oracle and
pass it back to Tomcat on request. 

 

BUT! I can't get it to work in test environment on Solaris under Tomcat
5.0.28. The major difference in configuration of these two environments
(except OS and Tomcat version, of course) is that on Solaris, two
applications are configured to run as virtual hosts and the third one
(the one in question) is in a path of one of those hosts. On Windows,
there are only two applications that are running from paths under a
common root.

 

To verify a guess about the problem, I replaced the password hash value
in the DB with clear text and this worked. I can't understand why Tomcat
ignores the digest parameter and tries to compare my hash code with the
clear text password sent by a login form. Here is realm config line in
the application context file: 

 

<Realm className="mydomain.MyRealm" digest="md5" />

 

If this were happening on Windows computer, I would consider researching
into Tomcat source code, perhaps under debugger. I can't do it on
Solaris, for a number of reasons.

 

Any ideas where to look for the problem cause? I've RTFM and STFW a lot,
but did not find a solution. I've even posted this question on
forum.java.sun.com - no result. 

 

Thanks In advance, 

 

Arkadi


Re: Tomcat authentication custom realm digest="md5" ignored

Posted by Mark Thomas <ma...@apache.org>.
Arkadi.Kosmynin@csiro.au wrote:
> 
> I have this setup working on my Windows development computer under
> Tomcat 5.5. Everything works fine. I get a hash value from Oracle and
> pass it back to Tomcat on request. 
> 
> BUT! I can't get it to work in test environment on Solaris under Tomcat
> 5.0.28. The major difference in configuration of these two environments
> (except OS and Tomcat version, of course) is that on Solaris, two
> applications are configured to run as virtual hosts and the third one
> (the one in question) is in a path of one of those hosts. On Windows,
> there are only two applications that are running from paths under a
> common root. 

Could be the result of bug fixed in 5.5.x. Try using the 5.5.x code in
your custom realm rather than extending the 5.0.x realm.

Mark


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org