mirror of
https://github.com/pi-hole/pi-hole
synced 2024-12-22 23:08:07 +00:00
Add X-Pi-hole header
This commit is contained in:
parent
7bc2844b9d
commit
f03303e5aa
@ -46,11 +46,16 @@ include_shell "/usr/share/lighttpd/include-conf-enabled.pl"
|
||||
# If the URL starts with /admin, it is the Web interface
|
||||
$HTTP["url"] =~ "^/admin/" {
|
||||
# Create a response header for debugging using curl -I
|
||||
setenv.add-response-header = ( "X-Frame-Options" => "DENY" )
|
||||
setenv.add-response-header = (
|
||||
"X-Pi-hole" => "The Pi-hole Web interface is working!",
|
||||
"X-Frame-Options" => "DENY"
|
||||
)
|
||||
}
|
||||
|
||||
# If the URL does not start with /admin, then it is a query for an ad domain
|
||||
$HTTP["url"] =~ "^(?!/admin)/.*" {
|
||||
# Create a response header for debugging using curl -I
|
||||
setenv.add-response-header = ( "X-Pi-hole" => "A black hole for Internet advertisements." )
|
||||
# rewrite only js requests
|
||||
url.rewrite = ("(.*).js" => "pihole/index.js")
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user