Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

.NET Forum


You are currently viewing our .NET Forum as a guest. Please register to participate.
Login



Reply
Old 06-02-2006, 04:06 PM Secure Directory
The Dorian's Avatar
Skilled Talker

Posts: 74
Location: Orange County, California
Trades: 0
Hi Guys,

I need to restrict access to all files within a particular directory...including image and jpeg files.

The username's and passwords are stored in a SQL database. Restricting access to .aspx files is easy, but I'm not sure how I should restrict access to the directory.

Any thoughts?

Thanks in advance for your help!
__________________
Dorian Collier

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
The Dorian is offline
Reply With Quote
View Public Profile Visit The Dorian's homepage!
 
 
Register now for full access!
Old 06-02-2006, 05:29 PM Re: Secure Directory
Minaki's Avatar
Defies a Status

Posts: 1,626
Location: Guildford, UK
Trades: 0
Firstly, store the files in a directory that isn't accessable from the web.

You can then write ASPX pages that firstly handle the authentication, and then load the file and write it out directly to the response stream.
__________________
Minaki Serinde MCP
"Wow, Linux is nearly on-par with Windows ME!"

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
Minaki is offline
Reply With Quote
View Public Profile Visit Minaki's homepage!
 
Old 06-07-2006, 03:49 AM Re: Secure Directory
Novice Talker

Posts: 5
Trades: 0
You can do it by placing a web.config file in that folder restricting access to all contents of it and any children folders (unless you place another web.config file further down the tree).

There's a tutorial here that should help you out. It explains how to use forms authentication and even shows how to use usernames and passwords from a database through SQL.
__________________
Daniel Punch

Please login or register to view this content. Registration is FREE
Punch is offline
Reply With Quote
View Public Profile Visit Punch's homepage!
 
Reply     « Reply to Secure Directory
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.19298 seconds with 12 queries