MCPcopy Create free account
hub / github.com/bugy/script-server / set_default_headers

Method set_default_headers

src/web/server.py:89–95  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

87
88class BaseRequestHandler(tornado.web.RequestHandler):
89 def set_default_headers(self):
90 self.set_header('X-Frame-Options', 'DENY')
91
92 if self.application.server_config.xsrf_protection == XSRF_PROTECTION_TOKEN:
93 # This is needed to initialize cookie (by default tornado does it only on html template rendering)
94 # noinspection PyStatementEffect
95 self.xsrf_token
96
97 def check_xsrf_cookie(self):
98 xsrf_protection = self.application.server_config.xsrf_protection

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected