nginx.conf
# nginx configuration
error_page 404 /404.php;
# Git folder vulnerability
location /.git {
deny all;
return 403;
}
location /controller {
deny all;
return 403;
}
location /docker_resources {
deny all;
return 403;
}
location /library {
deny all;
return 403;
}
location /service {
deny all;
return 403;
}
location /view {
deny all;
return 403;
}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
location ~ /\.ht {
deny all;
return 403;
}
# rewrite
location / {
try_files $uri $uri/ /index.php?$query_string;
}