Skip to content

Commit a688d04

Browse files
committed
Deny all php except whitelisted files
1 parent 22629ab commit a688d04

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

nginx.conf.sample

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -141,10 +141,6 @@ location /media/import/ {
141141
deny all;
142142
}
143143

144-
location ~ cron\.php {
145-
deny all;
146-
}
147-
148144
location ~ (index|get|static|report|404|503)\.php$ {
149145
try_files $uri =404;
150146
fastcgi_pass fastcgi_backend;
@@ -159,3 +155,7 @@ location ~ (index|get|static|report|404|503)\.php$ {
159155
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
160156
include fastcgi_params;
161157
}
158+
159+
location ~ \.php$ {
160+
deny all;
161+
}

0 commit comments

Comments
 (0)