Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

restricting JSP page from direct access..

 
Raza Mohd
Ranch Hand
Posts: 247
Java MyEclipse IDE MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am new to struts..I am working over a simple struts application . and my JAVA Server pages are in different folder outside WEB-INF .when i place the page URL it opens the page on browser.Can i restrict them to open.???
please let me aware of the solution..!
 
Ankit Garg
Sheriff
Posts: 9529
33
Android Google Web Toolkit Hibernate IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you can't move the JSP pages to WEB-INF directory, you can use a filter to block any requests for such JSP pages. If all those JSPs are in a particular directory like /jsp/, then you can map your filter to /jsp/* to block any request for contents of the /jsp directory. The filter will block only incoming requests and will allow request dispatching from action to the JSP...
 
Raza Mohd
Ranch Hand
Posts: 247
Java MyEclipse IDE MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you Ankit but can you please tell me how can i use filter to perform it.Where do i implement it.???
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic