| OLD | NEW |
| 1 # XSS and clickjacking prevention headers | 1 # XSS and clickjacking prevention headers |
| 2 | 2 |
| 3 set $csp_frame ""; | 3 set $csp_frame ""; |
| 4 if ($uri ~ ^/(:?\w\w(_\w\w)?/)?(?:index|firefox|chrome|opera|android|internet-ex
plorer|safari|yandex-browser|maxthon)?$) | 4 if ($uri ~ ^/(:?\w\w(_\w\w)?/)?(?:index|firefox|chrome|opera|android|internet-ex
plorer|safari|yandex-browser|maxthon)?$) |
| 5 { | 5 { |
| 6 set $csp_frame "; frame-src www.youtube-nocookie.com;"; | 6 set $csp_frame "; frame-src www.youtube-nocookie.com;"; |
| 7 } | 7 } |
| 8 add_header Content-Security-Policy "default-src 'self'; img-src * data:; style-s
rc 'self' 'unsafe-inline'; script-src 'self' 'unsafe-inline' 'unsafe-eval' $csp_
frame"; | 8 add_header Content-Security-Policy "default-src 'self'; img-src * data:; style-s
rc 'self' 'unsafe-inline'; script-src 'self' 'unsafe-inline' 'unsafe-eval' $csp_
frame"; |
| 9 add_header X-Frame-Options "sameorigin"; | 9 add_header X-Frame-Options "sameorigin"; |
| 10 | 10 |
| (...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 134 if ($arg_link = "adblock_browser_android_store") | 134 if ($arg_link = "adblock_browser_android_store") |
| 135 { | 135 { |
| 136 rewrite ^ https://play.google.com/store/apps/details?id=org.adblockplus.brow
ser? redirect; | 136 rewrite ^ https://play.google.com/store/apps/details?id=org.adblockplus.brow
ser? redirect; |
| 137 } | 137 } |
| 138 if ($arg_link = "adblock_browser_ios_store") | 138 if ($arg_link = "adblock_browser_ios_store") |
| 139 { | 139 { |
| 140 rewrite ^ https://geo.itunes.apple.com/us/app/adblock-browser-best-ad-blocke
r/id1015653330?mt=8? redirect; | 140 rewrite ^ https://geo.itunes.apple.com/us/app/adblock-browser-best-ad-blocke
r/id1015653330?mt=8? redirect; |
| 141 } | 141 } |
| 142 if ($arg_link = "adblock_browser_android_download") | 142 if ($arg_link = "adblock_browser_android_download") |
| 143 { | 143 { |
| 144 rewrite ^ https://downloads.adblockplus.org/adblockbrowser-1.0.0-arm.apk? re
direct; | 144 rewrite ^ https://downloads.adblockplus.org/adblockbrowser-1.1.0-arm.apk? re
direct; |
| 145 } | 145 } |
| 146 if ($arg_link = "adblock_plus_safari_ios_support") | 146 if ($arg_link = "adblock_plus_safari_ios_support") |
| 147 { | 147 { |
| 148 rewrite ^ /forum/viewforum.php?f=26? redirect; | 148 rewrite ^ /forum/viewforum.php?f=26? redirect; |
| 149 } | 149 } |
| 150 if ($arg_link = "adblock_plus_safari_ios_store") | 150 if ($arg_link = "adblock_plus_safari_ios_store") |
| 151 { | 151 { |
| 152 rewrite ^ https://itunes.apple.com/app/adblock-plus-abp/id1028871868? redire
ct; | 152 rewrite ^ https://itunes.apple.com/app/adblock-plus-abp/id1028871868? redire
ct; |
| 153 } | 153 } |
| 154 | 154 |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 287 location /403.html | 287 location /403.html |
| 288 { | 288 { |
| 289 try_files $uri @proxied; | 289 try_files $uri @proxied; |
| 290 } | 290 } |
| 291 location @proxied | 291 location @proxied |
| 292 { | 292 { |
| 293 proxy_pass https://server16.adblockplus.org; | 293 proxy_pass https://server16.adblockplus.org; |
| 294 proxy_set_header Host adblockplus.org; | 294 proxy_set_header Host adblockplus.org; |
| 295 proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | 295 proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; |
| 296 } | 296 } |
| OLD | NEW |