1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
| cat nginx/default.conf
server { listen 443 ssl http2; listen [::]:443 ssl http2;
add_header Strict-Transport-Security "max-age=31536000" always;
ssl_session_cache shared:SSL:20m; ssl_session_timeout 10m;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2; ssl_prefer_server_ciphers on; ssl_ciphers "ECDH+AESGCM:ECDH+AES256:ECDH+AES128:!ADH:!AECDH:!MD5;";
ssl_stapling on; ssl_stapling_verify on; resolver 8.8.8.8 8.8.4.4;
root /var/www/html; index index.php;
if ( $geoip2_data_country_code = CN ) { return 403; }
if ( $geoip2_data_city_name = Zhengzhou ) { return 403; }
|