summaryrefslogtreecommitdiffstats
path: root/Bugzilla
diff options
context:
space:
mode:
Diffstat (limited to 'Bugzilla')
-rw-r--r--Bugzilla/CGI.pm6
1 files changed, 6 insertions, 0 deletions
diff --git a/Bugzilla/CGI.pm b/Bugzilla/CGI.pm
index b32f76ae0..7c42d6f63 100644
--- a/Bugzilla/CGI.pm
+++ b/Bugzilla/CGI.pm
@@ -287,6 +287,12 @@ sub header {
unshift(@_, '-strict_transport_security' => $sts_opts);
}
+ # Add X-Frame-Options header to prevent framing and subsequent
+ # possible clickjacking problems.
+ unless ($self->url_is_attachment_base) {
+ unshift(@_, '-x_frame_options' => 'SAMEORIGIN');
+ }
+
return $self->SUPER::header(@_) || "";
}