File manager - Edit - /opt/cpguard/cpg-nginx/conf/captcha.conf
Back
server { listen 9096 default_server; server_name _; root /opt/cpguard/app/api/public/captcha; access_log off; etag off; keepalive_timeout 0; # Security and Cache Headers add_header Cache-Control "no-store, no-cache, must-revalidate, max-age=0" always; add_header Pragma "no-cache" always; add_header Expires "0" always; add_header X-Frame-Options "SAMEORIGIN"; # 1. The Captcha Processor location = /captcha.php { include fastcgi_params; fastcgi_pass unix:/opt/cpguard/cpg-php-fpm/var/run/cpgphp-cgi.sock; fastcgi_index captcha.php; fastcgi_param SCRIPT_FILENAME $document_root/captcha.php; } # 2. Asset Blocker (Save Bandwidth) location ~* \.(jpg|jpeg|gif|png|bmp|webp|ico|svg|tiff|css|js|woff|woff2|ttf|eot|map|json|pdf|doc|docx|xls|xlsx|ppt|pptx|txt|rtf|zip|rar|7z|tar|gz|bz2|iso|mp3|mp4|avi|mov|mpeg|flv|wav|ogg)$ { return 444; } # 3. Default Catch-All -> Show the HTML Interface location / { rewrite ^ /http.html break; } } server { listen 9097 default_server ssl; server_name _; # Fallback Self-Signed Certs ssl_certificate /opt/cpguard/cpg-nginx/ssl/cpg.pem; ssl_certificate_key /opt/cpguard/cpg-nginx/ssl/cpg.key; root /opt/cpguard/app/api/public/captcha; access_log off; etag off; keepalive_timeout 0; # Absolute no-cache on captcha add_header Cache-Control "no-store, no-cache, must-revalidate, max-age=0" always; add_header Pragma "no-cache" always; add_header Expires "0" always; location = /altcha.php { include fastcgi_params; fastcgi_pass unix:/opt/cpguard/cpg-php-fpm/var/run/cpgphp-cgi.sock; fastcgi_index altcha.php; fastcgi_param SCRIPT_FILENAME $document_root/altcha.php; } # This saves bandwidth. Nginx simply hangs up on them. location ~* \.(jpg|jpeg|gif|png|bmp|webp|ico|svg|tiff|css|js|woff|woff2|ttf|eot|map|json|pdf|doc|docx|xls|xlsx|ppt|pptx|txt|rtf|zip|rar|7z|tar|gz|bz2|iso|mp3|mp4|avi|mov|mpeg|flv|wav|ogg)$ { return 444; } location / { rewrite ^ /https.html break; } } include captcha/*.conf;
| ver. 1.4 |
Github
|
.
| PHP 8.1.34 | Generation time: 0.02 |
proxy
|
phpinfo
|
Settings