Skip to content

Commit

Permalink
set HSTS header
Browse files Browse the repository at this point in the history
  • Loading branch information
snarfed committed Sep 1, 2016
1 parent 855fc2e commit 285bd06
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion app.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,12 @@ class FrontPageHandler(webapp2.RequestHandler):
"""Renders and serves /, ie the front page.
"""
def get(self):
self.response.headers['Content-Type'] = 'text/html'
self.response.headers.update({
'Access-Control-Allow-Origin': '*',
'Strict-Transport-Security':
'max-age=16070400; includeSubDomains; preload', # 6 months
'Content-Type': 'text/html',
})

vars = dict(self.request.params)
key = vars.get('auth_entity')
Expand Down

0 comments on commit 285bd06

Please sign in to comment.