mirror of
https://github.com/myronblair/orbis-hosting-portal
synced 2026-07-29 05:33:30 -05:00
Compare commits
2 Commits
b9ebc760e8
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| ea58754e62 | |||
| 8ad58278d0 |
@@ -0,0 +1,10 @@
|
|||||||
|
# Block direct web access to the .git directory and other dotfiles.
|
||||||
|
# The .git folder lives inside public_html (docRoot) and was found to be
|
||||||
|
# directly downloadable over HTTPS (e.g. https://orbis.orbishosting.com/.git/config),
|
||||||
|
# which leaked a live GitHub personal access token embedded in the remote URL.
|
||||||
|
# Note: standard Apache access-control directives (RedirectMatch, FilesMatch/
|
||||||
|
# Require all denied, Order/Deny) are silently ignored on this LiteSpeed vhost.
|
||||||
|
# Only mod_rewrite rules are honored (confirmed via testing), hence this form.
|
||||||
|
RewriteEngine On
|
||||||
|
RewriteCond %{REQUEST_URI} ^/\.git
|
||||||
|
RewriteRule .* - [F,L]
|
||||||
@@ -62,6 +62,11 @@ rewrite {
|
|||||||
autoLoadHtaccess 1
|
autoLoadHtaccess 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
context /.git {
|
||||||
|
location /dev/null
|
||||||
|
allowBrowse 0
|
||||||
|
}
|
||||||
|
|
||||||
context /.well-known/acme-challenge {
|
context /.well-known/acme-challenge {
|
||||||
location /usr/local/lsws/Example/html/.well-known/acme-challenge
|
location /usr/local/lsws/Example/html/.well-known/acme-challenge
|
||||||
allowBrowse 1
|
allowBrowse 1
|
||||||
|
|||||||
Reference in New Issue
Block a user