473,386 Members | 1,835 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

ASP Equivilant to .htaccess ?

Does ASP have a file whose function is similar to .htaccess on Apache? I'm
looking to protect subdirectory content.

Jul 19 '05 #1
4 10091
No, it doesn't, at least not as far up to IIS 5. I don't know about IIS 6,
but I don't think that does either. Unfortunately, the ways of acheiving
the same results of .htaccess are much more server intensive than the way
..htaccess works. There are components you can use to mimic .htaccess
functionality, or you can stream your files back after verifying things
you'd like to verify, such as http_referer.

http://www.aspfaq.com/show.asp?id=2276

Ray at work
"Bill" <no*****@fooemail.com> wrote in message
news:eW**************@TK2MSFTNGP09.phx.gbl...
Does ASP have a file whose function is similar to .htaccess on Apache? I'm
looking to protect subdirectory content.

Jul 19 '05 #2

I recently ran up against this issue and came up with a pretty good
solution.

Here is what I did-

Created an account with the same username and password as the logged in
users userID (stored in a session)
The host I go through has ASPuser installed, so I used this to impersonate a
login based on the users userID (stored in a session) and then streamed the
file to them if it authenticated. This way it is impossible to link directly
to a file unless your userID matches the current session.

Does this sound fairly fool proof??


"Bill" <no*****@fooemail.com> wrote in message
news:eW**************@TK2MSFTNGP09.phx.gbl...
Does ASP have a file whose function is similar to .htaccess on Apache? I'm
looking to protect subdirectory content.

Jul 19 '05 #3
My knowledge of Apache and ASP.net are both limited, but does this help?

http://msdn.microsoft.com/library/en...horization.asp

Paul

"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:O9**************@TK2MSFTNGP12.phx.gbl...
No, it doesn't, at least not as far up to IIS 5. I don't know about IIS 6, but I don't think that does either. Unfortunately, the ways of acheiving
the same results of .htaccess are much more server intensive than the way
.htaccess works. There are components you can use to mimic .htaccess
functionality, or you can stream your files back after verifying things
you'd like to verify, such as http_referer.

http://www.aspfaq.com/show.asp?id=2276

Ray at work
"Bill" <no*****@fooemail.com> wrote in message
news:eW**************@TK2MSFTNGP09.phx.gbl...
Does ASP have a file whose function is similar to .htaccess on Apache? I'm looking to protect subdirectory content.


Jul 19 '05 #4
This KB article is named "HOW TO: Migrate .Htaccess Data in a
UNIX-to-Windows Migration", but it doesn't look useful to me. It only tells
you how to migrate the most basic of folder settings.

http://support.microsoft.com/default...b;en-us;324064

(also see my other post)

Paul

"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:O9**************@TK2MSFTNGP12.phx.gbl...
No, it doesn't, at least not as far up to IIS 5. I don't know about IIS 6, but I don't think that does either. Unfortunately, the ways of acheiving
the same results of .htaccess are much more server intensive than the way
.htaccess works. There are components you can use to mimic .htaccess
functionality, or you can stream your files back after verifying things
you'd like to verify, such as http_referer.

http://www.aspfaq.com/show.asp?id=2276

Ray at work
"Bill" <no*****@fooemail.com> wrote in message
news:eW**************@TK2MSFTNGP09.phx.gbl...
Does ASP have a file whose function is similar to .htaccess on Apache? I'm looking to protect subdirectory content.


Jul 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: yawnmoth | last post by:
i'm trying to write a php script that will password protect some random directory by creating a .htaccess file, and a password file to accompany the .htaccess file, and it isn't working... ...
8
by: Joshua Beall | last post by:
Hi All, How do I disable magic quotes via .htaccess? I put the following file in my webroot, but it does not disable magic_quotes_gpc (according to phpinfo(), both the local and master value...
4
by: Ivo | last post by:
Greetings newsgroup, I am moving some php scripts to a new host. While getting to know the server, I ran into a strange problem. If I add a .htaccess file, or more specifically: a .htaccess with...
7
by: John | last post by:
Hello. I want to get this blasted .htaccess file sorted out, so I can have sessions without register_globals being on. I have looked everywhere for info on this and I mean everywhere...
0
by: Stoco | last post by:
I am trying to create a generic interface that will manage various ..htaccess protected directories. In the ideal world, the .htaccess would trigger a cgi script that would take login information...
0
by: Jack Hambabo | last post by:
Hi, I'm searching for a php script that can find out whether the current user (I know _SERVER will give me the name for non-cgi php) has the right to view a specific file. My dream is that I...
1
by: nickyeng | last post by:
I have checked this info from apache website, and i confused with it. Procteing System files it said: To run a really tight ship, you'll want to stop users from setting up .htaccess files...
0
by: asherwolf | last post by:
Hi, I'm trying to do something I think is pretty neat, but I've just about pulled my hair out by the behavior of my server. I'm hosting on GoDaddy, using a subdomain (www.mywebpage.com maps to...
2
by: jaanus | last post by:
Here we go... What I have been trying to do is to forward all http requests containing /cms/ to http://cms.mydomain.com/ example1: http://host1.mydomain.com/cms/init.php would be parsed from...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.