Last active
August 29, 2015 14:02
-
-
Save gwarnants/53bda562e0a3ad94fad6 to your computer and use it in GitHub Desktop.
Cross version Apache access control
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
<Directory "/var/web/www/"> | |
# use mod_authz_host since Apache 2.4 | |
<IfDefine APACHE24> | |
Require local | |
</IfDefine> | |
# use mod_access before 2.4 | |
<IfDefine !APACHE24> | |
Order Deny,Allow | |
Deny from all | |
Allow from 127.0.0.1 ::1 localhost | |
</IfDefine> | |
</Directory> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment