[jboss-user] [Tomcat, HTTPD, Servlets & JSP] - Forms Authtentication not forwarding to correct page.
kazan77777
do-not-reply at jboss.com
Sat Apr 11 10:39:10 EDT 2009
I am implementing forms authentication, but after I login I am forwarded to my .css file.
If I launch my web browser and type in something like this:
http://localhost/intranet/projects.faces
I am forwarded to my login page. I proceed to enter my credentials, then hit submit.
Jboss authenticates me. However, I am forward to my applications .css file, which resides in intranet/css.
This doesn't make any since to me. I am expecting it to forward to the intended url, which is http://localhost/intranet/projects.faces.
I am using JBoss 5.0.1.
Can someone give me a hand?
My login config is like this:
<application-policy name="other">
| <authentication>
| <login-module code="org.jboss.security.auth.spi.DatabaseServerLoginModule" flag="required">
| <module-option name="dsJndiName">java:/MySqlDS</module-option>
| <module-option name="principalsQuery">
| SELECT
| password
| FROM
| appuser
| WHERE
| user_name=?
| </module-option>
| <module-option name="rolesQuery">
| SELECT
| 'APPUSER' role_name,
| 'Roles'
| FROM
| appuser u
| WHERE
| u.user_name=?
| </module-option>
| </login-module>
| </authentication>
| </application-policy>
|
My web.xml has this:
| <security-constraint>
| <web-resource-collection>
| <web-resource-name>Protected Area</web-resource-name>
| <url-pattern>/*</url-pattern>
| <http-method>DELETE</http-method>
| <http-method>GET</http-method>
| <http-method>POST</http-method>
| <http-method>PUT</http-method>
| </web-resource-collection>
| <auth-constraint>
| <role-name>APPUSER</role-name>
| </auth-constraint>
| </security-constraint>
| <login-config>
| <auth-method>FORM</auth-method>
| <form-login-config>
| <form-login-page>/login.faces</form-login-page>
| <form-error-page>/login.faces</form-error-page>
| </form-login-config>
| </login-config>
| <security-role>
| <role-name>APPUSER</role-name>
| </security-role>
|
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4224989#4224989
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4224989
More information about the jboss-user
mailing list