diff options
author | Adam Spragg <adam@spragg-ssl.co.uk> | 2018-08-09 18:39:55 +0100 |
---|---|---|
committer | Adam Spragg <adam@spragg-ssl.co.uk> | 2018-08-09 18:39:55 +0100 |
commit | 4dd62a4934ca72a9ee6842da347408a28c5d490c (patch) | |
tree | 61e825b300af224fb1214993e04f687595f47ccd | |
parent | 01f92c573546fae2341e79346f043c0aacbdcbf7 (diff) |
Allow access to "hidden" files under /cgit.cgi/ directories
-rw-r--r-- | apache2.conf | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/apache2.conf b/apache2.conf index 12a4e24..42c4d25 100644 --- a/apache2.conf +++ b/apache2.conf @@ -158,9 +158,10 @@ RewriteRule !\. - [H=application/x-httpd-php] # Disallow access to files/directories whose names begin with "_" or "." - # (except for /.well-known/), returning a 404. + # (except for /.well-known/ or any /cgit.cgi/), returning a 404. # This makes those files appear to not exist. RewriteCond "%{REQUEST_URI}" "!^/.well-known/" + RewriteCond "%{REQUEST_URI}" "!/cgit.cgi/" RewriteRule "/[_.]" "-" [R=404,L] # Do not list files beginning with an underscore in directory listings |