I'm trying to get Tomcat FORM based authentication to work and I'm not having any luck. I'm sure it's something stupid I'm missing, but I haven't been able to figure it out.
I have the following in my <tomcatRoot>\webapps\RFS7\WEB-INF\web-xml
I have the following in my <tomcatRoot>\webapps\RFS7\WEB-INF\rfs7.xml (I want this login/security to only apply to this application, at least for now)
I have the following in the <TomcatRoot>\conf\tomcat-users.xml file:
And my login form contains (among other things) this:
When I bring up the application at this url: http://localhost/RFS7/request.jsp the page comes up perfectly, but I'm not prompted to login like I expected. What am I doing wrong?
Do I need to edit the server.xml at all? Any pointers or help are much appreciated. Thanks!
Ulf Dittmer
Marshal
Joined: Mar 22, 2005
Posts: 35241
7
posted
0
<url-pattern>/RFS7/*</url-pattern>
URL patterns are relative to the web app root; try "/*" instead.
I have the following in my <tomcatRoot>\webapps\RFS7\WEB-INF\rfs7.xml
What's the significance of this file?
I have the following in the <TomcatRoot>\conf\tomcat-users.xml file:
That file should contain the users and their password and roles; I'm surprised this doesn't cause an exception.
Thank you! It's working now. The main problem was the url-pattern.
The rfs7.xml was something I added as I tried to work through this. Somewhere I found information about adding an xml file specific to the application, but I'll just forget all about that. ;-) I deleted it.
And my tomcat-users did contain users, passwords and roles. I mistakenly posted the wrong file contents.
In any case, thank you very much for the help!
Karen
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to
run our stuff on 16 servers instead of 3.