Created
November 12, 2013 16:28
-
-
Save polds/7434000 to your computer and use it in GitHub Desktop.
Apache configuration to block access to .git folders.
This file contains hidden or 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
# | |
# Add this somewhere in your httpd.conf file. | |
# I recommend you put it near the same | |
# place that your .htaccess access | |
# exclusions are configured. | |
# | |
<Directorymatch "^/.*/\.git/"> | |
Order deny,allow | |
Deny from all | |
</Directorymatch> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment