Created
May 15, 2015 17:11
-
-
Save loulou2u/7818c6c9b18a4af8e09c to your computer and use it in GitHub Desktop.
.htaccess file to determine SECURED URI
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SetEnvIfNoCase Request_URI "^/authenticated-directory/*" SECURED | |
# enforce auth if SECURED=1 | |
AuthType Basic | |
AuthName "Login Required" | |
AuthUserFile /path/to/.htpasswd | |
Require valid-user | |
Order allow,deny | |
Allow from all | |
Deny from env=SECURED | |
Satisfy any |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment