2
votes

I'm trying to password protect a directory on a server that's running IIS.

I've put the following in the .htaccess file in that directory - AuthName "Restricted Area" AuthType Basic AuthUserFile /path/.htpasswd AuthGroupFile /dev/null require valid-user

I've tried a whole bunch of different paths and although it's asking for a username and password it won't take it. I've tried using the path provided by _SERVER["PATH_TRANSLATED"] but that's no help either.

Is this a problem with my path, or does IIS just not support .htpasswd?

3

3 Answers

1
votes

IIS does not support .htpasswd or .htaccess.

3
votes

Helicon Ape (http://www.helicontech.com/ape naturally supports .htpasswd file with all these authentication options you’ve mentioned. The software also implements a bunch of other Apache-like features. As regarding authentication, you may also be interesting in these articles: http://helicontech.blogspot.com/search/label/mod_auth

Thank you.

0
votes

Natively IIS does not support the htpasswd.

You can get IISPassword for IIS from here if you really want to use similar files under IIS.