Uploaded document security in ASP.net

G

Guest

Hi all,

my asp.net page lets the users uploads documents up to a folder on the
webserver and then shows hyperlinks on a page pointing to these documents so
that the user can click them open and all this is only for users logged in
only. But the problem is that ones the user sees the name and part of the
document they are able to browse to the document using this url without even
logging in to the website,question is how can i restrict the user so that the
only way he can access documents form this folder is if they log into the
website.

Please suggest.!!
Sameer
 
G

Guest

Teemu, thanks for your reply but what if the user is uploading files with
different extensions that are not registered with IIS, they woudl be able to
be viewed by the users unless i regsiter their extension with IIS. Other then
this, isnt there any other way that i can restrict access to these file for
users not logged in the application?

thanks
 
T

Teemu Keiski

Hi,

I'd say you'd probably want to restrict the types of files to be uploaded,
when you can do this. Basically, you could map all extensions to ASP.NET
(just use wildcard *) but it has performance penalty also, since mapping
means that files are served through ASP.NET pipeline.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,431
Messages
2,571,677
Members
48,796
Latest member
Greg L.

Latest Threads

Top