File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Security and the fly likes Problem Using j_security_check Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Security
Bookmark "Problem Using j_security_check" Watch "Problem Using j_security_check" New topic

Problem Using j_security_check

Ranch Hand

Joined: Dec 16, 2004
Posts: 63
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

Joined: May 03, 2004
Posts: 21
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

Joined: Feb 24, 2005
Posts: 1
Hy Shantanu,

About the subject here
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"


After that I can successfully access a protected ressource.

I agree. Here's the link:
subject: Problem Using j_security_check
It's not a secret anymore!