Skip to content
This repository has been archived by the owner on Jul 13, 2023. It is now read-only.

feat: add Strict-Transport-Security header #1035

Merged
merged 1 commit into from
Oct 4, 2017
Merged

feat: add Strict-Transport-Security header #1035

merged 1 commit into from
Oct 4, 2017

Conversation

jrconlin
Copy link
Member

@jrconlin jrconlin commented Oct 4, 2017

Closes #1031

@jrconlin jrconlin requested review from pjenvey and bbangert October 4, 2017 18:48
@codecov-io
Copy link

codecov-io commented Oct 4, 2017

Codecov Report

Merging #1035 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   99.76%   99.76%   +<.01%     
==========================================
  Files          55       55              
  Lines        8799     8811      +12     
==========================================
+ Hits         8778     8790      +12     
  Misses         21       21
Impacted Files Coverage Δ
autopush/web/base.py 100% <ø> (ø) ⬆️
autopush/config.py 100% <100%> (ø) ⬆️
autopush/tests/test_web_base.py 100% <100%> (ø) ⬆️
autopush/main_argparse.py 100% <100%> (ø) ⬆️
autopush/tests/test_main.py 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a9a1330...4e79dce. Read the comment docs.

if self.conf.sts_max_age:
self.set_header("Strict-Transport-Security",
";".join([
"max-age={}".format(self.conf.sts_max_age),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

eh could have just done it all in the .format string but no biggie

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thought about it. Decided on this partly because there's a few other potential options and the wrapping would have gotten ugly.

@bbangert bbangert merged commit a933325 into master Oct 4, 2017
@bbangert bbangert deleted the feat/1031 branch October 4, 2017 20:53
@jrconlin jrconlin restored the feat/1031 branch October 12, 2017 18:17
@jrconlin jrconlin deleted the feat/1031 branch October 12, 2017 18:19
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants