This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Problem Using j_security_check

 
Vikas
Ranch Hand
Posts: 63
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello All,

I am trying to login to secured pages using j_security_check and JDBCRealm but when I try to login, the server displays me the following error message:-

Apache Tomcat/4.0.4-b3 - HTTP 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).


Can anyone help me to fix this as I have tried alot to fix this but no results.
 
Chris Wagnor
Greenhorn
Posts: 21
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check whether the WEB.xml file has the correct mapping for the j_security_check. As I faced the same problem with Weblogic and fixed up using the same.

Make sure that your mapping is referring to the class in Apache. As this is the only way it can be solved.
 
Calin Lasting
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hy Shantanu,

About the subject here http://www.coderanch.com/t/133606/Security/security-check
how exactly has to be done the mapping configuration of j_security_check? Have you an example? What class must be associated? I tryed something like this but I still have the message "HTTP Status 400 - Invalid direct reference to form login page"

<filter>
<filter-name>LoginFilter</filter-name>
<display-name>PostLoginFilter</display-name>
<filter-class>com.x.webapp.LoginFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>LoginFilter</filter-name>
<url-pattern>/j_security_check</url-pattern>
</filter-mapping>

After that I can successfully access a protected ressource.

Thanks.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic