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

Custom RequestProcessor

Abhay Kumar J
Greenhorn

Joined: Feb 20, 2009
Posts: 1
I'm developing a struts application, in which I've extended the RequestProcessor to check the session. Everything is fine and works as expected. But an unauthenticated user can simply access the JSP pages directly. Here the request to the JSP page completely bypasses the RequestProcessor, only requests with logical labels like xyz.do go through the RequestProcessor.

After searching the web, one solution is to keep the JSP pages inside the WEB-INF directory. But is it possible to send every request through the RequestProcessor?
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

The RequestProcessor only processes Struts 1 requests. In other words, whatever the Struts 1 servlet is mapped to (*.do by default).

Putting the JSPs under /WEB-INF is the canonical and recommended solution.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Custom RequestProcessor