summaryrefslogtreecommitdiffstats
path: root/api/context.go
diff options
context:
space:
mode:
authornickago <ngonella@calpoly.edu>2015-07-27 08:29:08 -0700
committernickago <ngonella@calpoly.edu>2015-07-27 08:29:08 -0700
commit18d160bec53c36b604900506a461598a7082ff9b (patch)
treeb3e98d448655bc8b02a025604e7c39d88803b81b /api/context.go
parentc0d225c6d8ac3f1f7f07047f6527d16d173d3550 (diff)
downloadchat-18d160bec53c36b604900506a461598a7082ff9b.tar.gz
chat-18d160bec53c36b604900506a461598a7082ff9b.tar.bz2
chat-18d160bec53c36b604900506a461598a7082ff9b.zip
Centralized header additions and removed duplicate code
Diffstat (limited to 'api/context.go')
-rw-r--r--api/context.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/api/context.go b/api/context.go
index ac9dffcbc..036128a00 100644
--- a/api/context.go
+++ b/api/context.go
@@ -100,6 +100,8 @@ func (h handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
w.Header().Set(model.HEADER_REQUEST_ID, c.RequestId)
w.Header().Set(model.HEADER_VERSION_ID, utils.Cfg.ServiceSettings.Version)
+ w.Header().Set("X-FRAME-OPTIONS", "DENY")
+ w.Header().Set("Content-Security-Policy", "frame-ancestors none")
sessionId := ""