File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

preventing direct access to html files

 
Raj Kumar Bindal
Ranch Hand
Posts: 418
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my application, i am redirecting my control to a html file using response.sendRedirect(). Once this is done, that html file is freely accessible even if the url is copy-pasted into other browser. Is there any way that we can find out if client is trying to access that file directly.
I cannot put file inside web-inf,because response.sendRedirect() is not authorised to redirect control to files inside web-inf.
Any suggestions.
 
Himanshu Gupta
Ranch Hand
Posts: 598
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can write a servlet which will send content of your html file to the client end.
[ December 15, 2008: Message edited by: Himanshu Gupta ]
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic