瀏覽代碼

changed nginx X-Frame-Option to SAMEORIGIN

Bachir Soussi Chiadmi 5 年之前
父節點
當前提交
934874b297
共有 4 個文件被更改,包括 11 次插入1 次删除
  1. 1 1
      assets/drupal-ssl.nginxconf
  2. 4 0
      assets/drupal.nginxconf
  3. 3 0
      assets/simple-phpfpm-ssl.nginxconf
  4. 3 0
      assets/simple-phpfpm.nginxconf

+ 1 - 1
assets/drupal-ssl.nginxconf

@@ -136,5 +136,5 @@ server {
   }
 
   # website should not be displayed inside a <frame>, an <iframe> or an <object>
-  add_header X-Frame-Options DENY;
+  add_header X-Frame-Options SAMEORIGIN;
 }

+ 4 - 0
assets/drupal.nginxconf

@@ -110,4 +110,8 @@ server {
       expires max;
       log_not_found off;
     }
+
+
+    # website should not be displayed inside a <frame>, an <iframe> or an <object>
+    add_header X-Frame-Options SAMEORIGIN;
 }

+ 3 - 0
assets/simple-phpfpm-ssl.nginxconf

@@ -59,4 +59,7 @@ server {
   location ~ /\.ht {
     deny all;
   }
+
+  # website should not be displayed inside a <frame>, an <iframe> or an <object>
+  add_header X-Frame-Options SAMEORIGIN;
 }

+ 3 - 0
assets/simple-phpfpm.nginxconf

@@ -35,4 +35,7 @@ server {
   location ~ /\.ht {
     deny all;
   }
+
+  # website should not be displayed inside a <frame>, an <iframe> or an <object>
+  add_header X-Frame-Options SAMEORIGIN;
 }