Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- listen 80 default_server;
- listen [::]:80 default_server;
- # SSL configuration
- #
- # listen 443 ssl default_server;
- # listen [::]:443 ssl default_server;
- #
- # Self signed certs generated by the ssl-cert package
- # Don't use them in a production server!
- #
- # include snippets/snakeoil.conf;
- root /var/www/html;
- # Add index.php to the list if you are using PHP
- index index.php index.html;
- server_name rpheaven.org www.rpheaven.org;
- location = /forum/conf_global.php
- {
- deny all;
- }
- location ~ /forum/uploads/.*\.(php|pl|rb|sh)$ {
- deny all;
- }
- location ~ /configuration/.*\.(php)$ {
- deny all;
- }
- location ~ /cache/.*\.(php)$ {
- deny all;
- }
- if ($http_user_agent = "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.110 Safari/537.36"){
- return 403;}
- deny 5.12.8.241;
- deny 188.25.38.137;
- deny 5.12.180.102;
- deny 62.210.83.88;
- deny 67.85.171.216;
- deny 67.85.171.216;
- deny 104.200.151.59;
- deny 104.200.151.79;
- deny 124.169.216.215;
- #deny 95.76.22.151;
- location ~ \.php$ {
- try_files $uri =404;
- fastcgi_split_path_info ^(.+\.php)(/.+)$;
- # NOTE: You should have "cgi.fix_pathinfo = 0;" in php.ini
- # With php5-cgi alone:
- #fastcgi_pass 127.0.0.1:9000;
- # With php5-fpm:
- fastcgi_pass unix:/var/run/php/php5.6-fpm.sock;
- fastcgi_index index.php;
- fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
- include fastcgi_params;
- }
- # deny access to .htaccess files, if Apache's document root
- # concurs with nginx's one
- #
- #location ~ /\.ht {
- # deny all;
- #}
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement