about summary refs log tree commit diff
diff options
context:
space:
mode:
authorThibaut Girka <thib@sitedethib.com>2018-08-22 17:37:51 +0200
committerThibG <thib@sitedethib.com>2018-08-22 20:39:33 +0200
commit628fca50e20bcf41f206877083fc5ee8789c1088 (patch)
tree472b175a562cf26a7ec32d0d4576283e37c7ad19
parente7a72439f1baa90f66e9333cfca72ed2079d2d12 (diff)
Override CSP setting in the embed controller to allow frames
-rw-r--r--app/controllers/statuses_controller.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/controllers/statuses_controller.rb b/app/controllers/statuses_controller.rb
index bc711a8e4..cf750f4bb 100644
--- a/app/controllers/statuses_controller.rb
+++ b/app/controllers/statuses_controller.rb
@@ -19,6 +19,10 @@ class StatusesController < ApplicationController
   before_action :set_referrer_policy_header, only: [:show]
   before_action :set_cache_headers
 
+  content_security_policy only: :embed do |p|
+    p.frame_ancestors(false)
+  end
+
   def show
     respond_to do |format|
       format.html do