summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author53hornet <atc@53hor.net>2021-12-14 16:29:17 -0500
committer53hornet <atc@53hor.net>2021-12-14 16:29:17 -0500
commit3ea2f0665bb7f0d1c32186e068638274b02cf6f5 (patch)
tree5faf2b37985a76a56ec838bd03ecc2d0d33f220d
parent5f96592609c82cfff9056b799782e1dd6ebbeef9 (diff)
downloadwww-3ea2f0665bb7f0d1c32186e068638274b02cf6f5.tar.xz
www-3ea2f0665bb7f0d1c32186e068638274b02cf6f5.zip
fix: deny access to drafts
-rw-r--r--usr/local/etc/lighttpd/conf.d/access.conf4
-rw-r--r--usr/local/etc/lighttpd/lighttpd.conf1
2 files changed, 5 insertions, 0 deletions
diff --git a/usr/local/etc/lighttpd/conf.d/access.conf b/usr/local/etc/lighttpd/conf.d/access.conf
new file mode 100644
index 0000000..ea3f1d8
--- /dev/null
+++ b/usr/local/etc/lighttpd/conf.d/access.conf
@@ -0,0 +1,4 @@
+server.modules += ( "mod_access" )
+$HTTP["url"] =~ "^/drafts/" {
+ url.access-deny = ("")
+}
diff --git a/usr/local/etc/lighttpd/lighttpd.conf b/usr/local/etc/lighttpd/lighttpd.conf
index 8fc90fb..4d98d5b 100644
--- a/usr/local/etc/lighttpd/lighttpd.conf
+++ b/usr/local/etc/lighttpd/lighttpd.conf
@@ -3,6 +3,7 @@ include "conf.d/access_log.conf"
include "conf.d/dirlisting.conf"
include "conf.d/mime.conf"
include "conf.d/cgi.conf"
+include "conf.d/access.conf"
index-file.names += ("index.php")
server.error-handler-404 = "/index.php"
server.document-root = "/var/www"