Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to prevent direct file download??

843840Aug 17 2007 — edited Aug 19 2007
m using jsp to create a portal..
users can login in and can download resources...
i have used sessions to check whether the user is logged in to download d resource...
once he logged out he shouldnt access the resource.... i have cleared the session values also....
but the problem is even though he logs out he is able to access the resource but getting the file path when he was previously logged in....
Is there a way to prevent this???
how can i prevent them by getting those file path??

for ex.. if the resource location is like this http:/locatlhost:8080/files/filename.txt

should i give the file path like this
download
if so he will able to identify the path isnt it??

is there any way or code to encode the url ?? so that they wont be getting the exact path???

this is like preventing file(present in mail) download after u logged out ..
can any one to me how to prevent this?

Message was edited by:
sriramnj86
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 16 2007
Added on Aug 17 2007
3 comments
239 views