Problem using Tomcat REALM to authenticate with Spring Framework
Good morning you all! My name is Felipe, I´m a software developer from Brazil, and I´m beggining on Java WEB development. Right now, I´m using Java 5.0, Tomcat 5.5.15 and Spring Framework 1.2.7, but I was used to use the Struts MVC.
In the beggining of my studies, I was trying to develop a simple web application hosted on Tomcat that use a controller to return me a view. Spring Framework granted it in less than 50 minutes, It´s really a suberb framework.
But, one thing that I will have to use is some mechanism of user authentication and role access within application. I´ve already configured the REALM on Tomcat to work with Struts application, but, with Spring I can´t get it to work.
The problem is, when I try to access an protected content, The login page comes correctly. When I enter some bad login info, it sends me to the login error page, but, when I enter a correct login info, It shows me a page with the following info:Code:
from Status 400 - Invalid direct reference to form login page
type Status report
message Invalid direct reference to form login page
description The request sent by the client was syntactically incorrect (Invalid direct reference to form login page).
Apache Tomcat/5.5.15
And there is something weird about it all:
When the login fails, the tomcat console shows the logging information saying that it could return the loging error view succesfully. But, when loging was supposed to happen, the tomcat console shows nothing, it don´t post info into the log archive.
Some will say: quot;Why don´t you use ACEGI??quot;
The learning curve is too high, and right now, I cannot loose time, that´s why I´m trying to give REALM a second chance.
Thanks a lot! |