Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Max-Age is a nonnegative integer, not only positive. #18

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions draft-west-http-state-tokens.html
Original file line number Diff line number Diff line change
Expand Up @@ -628,7 +628,7 @@ <h1 id="rfc.section.4.2">
<ul>
<li>Exactly one member whose key is <samp>key</samp>, and whose value is binary content (<a href="#I-D.ietf-httpbis-header-structure" class="xref">[I-D.ietf-httpbis-header-structure]</a>, Section 3.10) that encodes an key which can be used to generate a signature over outgoing requests.</li>
<li>Exactly one member whose key is <samp>delivery</samp>, and whose value is one of the following tokens (<a href="#I-D.ietf-httpbis-header-structure" class="xref">[I-D.ietf-httpbis-header-structure]</a>, Section 3.9): <samp>same-origin</samp>, <samp>same-site</samp>, or <samp>cross-site</samp>. <br><br> If the <samp>delivery</samp> member contains an unknown identifier, the member MUST be ignored.</li>
<li>Exactly one member whose key is <samp>max-age</samp>, and whose value is an integer (<a href="#I-D.ietf-httpbis-header-structure" class="xref">[I-D.ietf-httpbis-header-structure]</a>, Section 3.6) representing the server&#8217;s desired lifetime for its HTTP State Token. <br><br> If the <samp>max-age</samp> member contains anything other than a positive integer, the member MUST be ignored.</li>
<li>Exactly one member whose key is <samp>max-age</samp>, and whose value is an integer (<a href="#I-D.ietf-httpbis-header-structure" class="xref">[I-D.ietf-httpbis-header-structure]</a>, Section 3.6) representing the server&#8217;s desired lifetime for its HTTP State Token. <br><br> If the <samp>max-age</samp> member contains anything other than a nonnegative integer, the member MUST be ignored.</li>
</ul>
<p id="rfc.section.4.2.p.6">User agents will process the <samp>Sec-Http-State-Options</samp> header on incoming responses according to the processing rules described in <a href="#config" class="xref">Section 6</a>.</p>
<h1 id="rfc.section.4.2.1">
Expand Down Expand Up @@ -755,7 +755,7 @@ <h1 id="rfc.section.6">
<li>
<samp>header</samp> has a member named <samp>delivery</samp> whose value is not one of the following tokens (Section 3.9 of <a href="#I-D.ietf-httpbis-header-structure" class="xref">[I-D.ietf-httpbis-header-structure]</a>): &#8220;same-origin&#8221;, &#8220;same-site&#8221;, and &#8220;cross-site&#8221;.</li>
<li>
<samp>header</samp> has a member named <samp>max-age</samp> whose value is not a positive integer (Section 3.6 of <a href="#I-D.ietf-httpbis-header-structure" class="xref">[I-D.ietf-httpbis-header-structure]</a>).</li>
<samp>header</samp> has a member named <samp>max-age</samp> whose value is not a nonnegative integer (Section 3.6 of <a href="#I-D.ietf-httpbis-header-structure" class="xref">[I-D.ietf-httpbis-header-structure]</a>).</li>
</ul>
</li>
<li>If <samp>header</samp> has a member named <samp>key</samp>, set <samp>token</samp>&#8217;s <samp>key</samp> to the member&#8217;s value.</li>
Expand Down
4 changes: 2 additions & 2 deletions draft-west-http-state-tokens.md
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,7 @@ The dictionary MAY contain:
({{!I-D.ietf-httpbis-header-structure}}, Section 3.6) representing the server's desired lifetime
for its HTTP State Token.

If the `max-age` member contains anything other than a positive integer, the member MUST be
If the `max-age` member contains anything other than a nonnegative integer, the member MUST be
ignored.

User agents will process the `Sec-Http-State-Options` header on incoming responses according to the
Expand Down Expand Up @@ -549,7 +549,7 @@ intended to be called after the `Set-Cookie` header is handled in step 11.4 of S
* `header` has a member named `delivery` whose value is not one of the following tokens
(Section 3.9 of {{I-D.ietf-httpbis-header-structure}}): "same-origin", "same-site",
and "cross-site".
* `header` has a member named `max-age` whose value is not a positive integer (Section 3.6
* `header` has a member named `max-age` whose value is not a nonnegative integer (Section 3.6
of {{I-D.ietf-httpbis-header-structure}}).

3. If `header` has a member named `key`, set `token`'s `key` to the member's value.
Expand Down