OWASP / OWASP/ASVS

Clarification of language around HSTS

Open Beginner friendly
#3,364 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

4) proposal for review V3 (prev V50)
Dominant language
HTML
Stars
3.6k
Forks
831
Avg merge
7h 55m
Merged PRs (30d)
4

Description

The wording around the max-age parameter of HSTS is needlessly ambiguous especially in 3.4.1:

Verify that a Strict‑Transport‑Security header field is included on all responses to enforce an HTTP Strict Transport Security (HSTS) policy. A maximum age of at least 1 year must be defined, and for L2 and up, the policy must apply to all subdomains as well.

The problem here is the use of "maximum age", the sentence can be parsed as the maximum value of the parameter or the maximum value of max-age. This all hooks on the words "... at least ...", if they're missed on a skim read the sentence has a different meaning. The sentence caused confusion for our internal advice, as we tried to work out what the best recommendation for HSTS was.

To make it totally unambiguous it would be better to rephrase it to be explicit, something like:

Verify that a Strict‑Transport‑Security header field is included on all responses to enforce an HTTP Strict Transport Security (HSTS) policy. The max-age parameter should be set to at least 31536000 (one year). For L2 and up, the policy must apply to all subdomains as well.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate section 3.4.1 and search the repository for the quoted HSTS wording. Review the surrounding requirements and revise the language so the max-age parameter and one-year value are unambiguous while retaining the all-subdomains requirement for L2 and above. Done means the relevant standard text no longer invites the reported interpretation.

Written by the indexing model from the issue text.

Assessment

Domain
documentation, security
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
72/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.