File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Servlets and the fly likes Realm question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Realm question" Watch "Realm question" New topic
Author

Realm question

Atul Mishra
Ranch Hand

Joined: Jun 08, 2006
Posts: 140
Hi all,

I have a JAASRealm configured in my J2ee application which authenticates fine. The problem I am having is, I use login.jsp page to get username and password. After succesful authenication using realm, the user should go to next page, displayDetails.jsp
Where would I specify this displayDetails.jsp

Right now, here is how realm entry looks like in web.xml - This works fine, when I click login.jsp, enter details it goes to j_security_check and displays the login page back, doesnt go to next page.

Please help

Thanks

<security-constraint>
<display-name>User Security</display-name>
<web-resource-collection>
<web-resource-name>All contents</web-resource-name>
<description></description>
<url-pattern>/*</url-pattern>
<http-method>
GET</http-method>
<http-method>
PUT</http-method>
<http-method>
HEAD</http-method>
<http-method>
TRACE</http-method>
<http-method>
POST</http-method>
<http-method>
DELETE</http-method>
<http-method>
OPTIONS</http-method>
</web-resource-collection>
<auth-constraint>
<description></description>
<role-name>user</role-name>
<role-name>admin</role-name>
</auth-constraint>
</security-constraint>
<login-config>
<auth-method>FORM</auth-method>
<realm-name>testrealm</realm-name>
<form-login-config>
<form-login-page>/login.jsp</form-login-page>
<form-error-page>/logon-error.jsp</form-error-page>
</form-login-config>
</login-config>
<security-role>
<description></description>
<role-name>user</role-name>
</security-role>
<security-role>
<description></description>
<role-name>admin</role-name>
</security-role>
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Realm question
 
Similar Threads
Tomcat authentication and RACF
Form based login
Form Authentication not working
Form based authentication in java server faces.
Is auth-constraint related to security-role?