@@ -1981,8 +1981,8 @@ not always relevant and might require different behavior.
1981
1981
"<code> client</code> ".
1982
1982
1983
1983
<p> A <a for=/>request</a> has an associated
1984
- <dfn export for=request>top-level navigation initiator origin</dfn> ,
1985
- which is an <a for=/>origin</a> or null. Unless stated otherwise it is null.
1984
+ <dfn export for=request>top-level navigation initiator origin</dfn> , which is an <a for=/>origin</a>
1985
+ or null. Unless stated otherwise it is null.
1986
1986
1987
1987
<p class=note> "<code> client</code> " is changed to an <a for=/>origin</a> during
1988
1988
<a lt=fetch for=/>fetching</a> . It provides a convenient way for standards to not have to set
@@ -2301,7 +2301,7 @@ or "<code>object</code>".
2301
2301
not <a>same origin</a> with <var> lastURL</var> 's <a for=url>origin</a> , then set
2302
2302
<var> computedTaint</var> to "<code> same-site</code> ".
2303
2303
2304
- <li> Set <var> lastURL</var> to <var> url</var> .
2304
+ <li><p> Set <var> lastURL</var> to <var> url</var> .
2305
2305
</ol>
2306
2306
2307
2307
<li><p> Return <var> computedTaint</var> .
@@ -4286,25 +4286,25 @@ prefetch, or to treat it differently when counting page visits.
4286
4286
4287
4287
<h2 id=cookies>Cookies</h2>
4288
4288
4289
- <h3 id=cookie-header>`<code>Cookie</code>` header</h3>
4289
+ <p> The `<code> Cookie</code> ` request header and `<code> Set-Cookie</code> ` response headers are
4290
+ largely defined in their own specifications. We define additional infrastructure to be able to use
4291
+ them conveniently here. [[COOKIES]] .
4292
+
4290
4293
4291
- <p> The `<code> Cookie</code> ` header is largely defined in its own specification. We define
4292
- additional infrastructure to be able to use them conveniently here. [[COOKIES]] .
4294
+ <h3 id=cookie-header>`<code>Cookie</code>` header</h3>
4293
4295
4294
4296
<div algorithm>
4295
- <p> To <dfn>append a request `<code>Cookie</code>` header</dfn> ,
4296
- given a <a for=/>request</a> <var> request</var> :
4297
+ <p> To <dfn>append a request `<code>Cookie</code>` header</dfn> , given a <a for=/>request</a>
4298
+ <var> request</var> :
4297
4299
4298
4300
<ol>
4299
4301
<li><p> If the user agent is configured to disable cookies for <var> request</var> , then it should
4300
4302
return.
4301
4303
4302
4304
<li><p> Let |sameSite| be the result of [=determining the same-site mode=] for <var> request</var> .
4303
4305
4304
- <li><p> Let |isSecure| be false.
4305
-
4306
- <li><p> If <var> request</var> 's <a for=request>client</a> is a <a>secure context</a> , then set
4307
- |isSecure| to true.
4306
+ <li><p> Let |isSecure| be true if <var> request</var> 's <a for=request>current URL</a>' s
4307
+ <a for=url>scheme</a> is "<code> https</code> "; otherwise false.
4308
4308
4309
4309
<li>
4310
4310
<p> Let |httpOnlyAllowed| be true.
@@ -4328,21 +4328,21 @@ given a <a for=/>request</a> <var>request</var>:
4328
4328
</ol>
4329
4329
</div>
4330
4330
4331
+
4332
+ <h3 id=set-cookie-header>`<code>Set-Cookie</code>` header</h3>
4333
+
4331
4334
<div algorithm>
4332
- <p> To
4333
- <dfn>parse and store response `<code>Set-Cookie</code>` headers</dfn> ,
4334
- given a <a for=/>request</a> <var> request</var> and a <a for=/>response</a> <var> response</var> :
4335
+ <p> To <dfn>parse and store response `<code>Set-Cookie</code>` headers</dfn> , given a
4336
+ <a for=/>request</a> <var> request</var> and a <a for=/>response</a> <var> response</var> :
4335
4337
4336
4338
<ol>
4337
- <li><p> If the user agent is configured to disable cookies for <var> request</var> ,
4338
- then it should return.
4339
+ <li><p> If the user agent is configured to disable cookies for <var> request</var> , then it should
4340
+ return.
4339
4341
4340
4342
<li><p> Let |allowNonHostOnlyCookieForPublicSuffix| be false.
4341
4343
4342
- <li><p> Let |isSecure| be false.
4343
-
4344
- <li><p> If <var> request</var> 's <a for=request>current URL</a>' s <a for=url>scheme</a> is
4345
- "<code> https</code> ", then set |isSecure| to true.
4344
+ <li><p> Let |isSecure| be true if <var> request</var> 's <a for=request>current URL</a>' s
4345
+ <a for=url>scheme</a> is "<code> https</code> "; otherwise false.
4346
4346
4347
4347
<li>
4348
4348
<p> Let |httpOnlyAllowed| be true.
@@ -4351,30 +4351,32 @@ given a <a for=/>request</a> <var>request</var> and a <a for=/>response</a> <var
4351
4351
<code> document.cookie</code> getter steps for instance.
4352
4352
4353
4353
<li><p> Let |sameSiteStrictOrLaxAllowed| be true if the result of [=determine the same-site mode=]
4354
- for |request| is "<code> StrictOrLess </code> ", and false otherwise .
4354
+ for |request| is "<code> strict-or-less </code> "; otherwise false.
4355
4355
4356
- <li><p> <a for=list>For each</a> <var> header</var> of <var> response</var> 's
4357
- <a for=response>header list</a> :
4356
+ <li>
4357
+ <p> <a for=list>For each</a> <var> header</var> of <var> response</var> 's
4358
+ <a for=response>header list</a> :
4358
4359
4359
- <ol>
4360
- <li><p> If <var> header</var> 's <a for=header>name</a> is not a <a>byte-case-insensitive</a> match
4361
- for `<code> Set-Cookie</code> `, <a for=iteration>continue</a> .
4360
+ <ol>
4361
+ <li><p> If <var> header</var> 's <a for=header>name</a> is not a <a>byte-case-insensitive</a> match
4362
+ for `<code> Set-Cookie</code> `, then <a for=iteration>continue</a> .
4362
4363
4363
- <li><p> <a>Parse and store a cookie</a> given <var> header</var> 's <a for=header>value</a> ,
4364
- |isSecure|, <var> request</var> 's <a for=request>current URL</a>' s <a for=url>host</a> ,
4365
- <var> request</var> 's <a for=request>current URL</a>' s <a for=url>path</a> , |httpOnlyAllowed|,
4366
- |allowNonHostOnlyCookieForPublicSuffix|, and |sameSiteStrictOrLaxAllowed|.
4364
+ <li><p> <a>Parse and store a cookie</a> given <var> header</var> 's <a for=header>value</a> ,
4365
+ |isSecure|, <var> request</var> 's <a for=request>current URL</a>' s <a for=url>host</a> ,
4366
+ <var> request</var> 's <a for=request>current URL</a>' s <a for=url>path</a> , |httpOnlyAllowed|,
4367
+ |allowNonHostOnlyCookieForPublicSuffix|, and |sameSiteStrictOrLaxAllowed|.
4367
4368
4368
- <li><p> <a>Garbage collect cookies</a> given <var> request</var> 's
4369
- <a for=request>current URL</a> 's <a for=url>host</a> .
4370
- </ol>
4369
+ <li><p> <a>Garbage collect cookies</a> given <var> request</var> 's <a for=request>current URL</a>' s
4370
+ <a for=url>host</a> .
4371
+ </ol>
4372
+
4373
+ <p class=note> As noted elsewhere the `<code> Set-Cookie</code> ` header cannot be combined and
4374
+ therefore each occurrence is processed independently. This is not allowed for any other header.
4371
4375
</ol>
4372
4376
</div>
4373
4377
4374
- <h3 id=cookie-infrastructure>Cookie infrastructure</h3>
4375
4378
4376
- <p> These algorithms are not only for use with the `<code> Cookie</code> ` header, and are used in
4377
- other specifications.
4379
+ <h3 id=cookie-infrastructure>Cookie infrastructure</h3>
4378
4380
4379
4381
<div algorithm>
4380
4382
<p> To <dfn>determine the same-site mode</dfn> for a given <a for=/>request</a> <var> request</var> :
@@ -4384,20 +4386,20 @@ other specifications.
4384
4386
or "<code> POST</code> ".
4385
4387
4386
4388
<li><p> If <var> request</var> 's <a for=request>top-level navigation initiator origin</a> is not
4387
- null and is not <a for=/>same site</a> to <var> request</var> 's <a for=request>URL</a>' s
4388
- <a for=url>origin</a> , then return "<code> UnsetOrLess </code> ".
4389
+ null and is not <a for=/>same site</a> with <var> request</var> 's <a for=request>URL</a>' s
4390
+ <a for=url>origin</a> , then return "<code> unset-or-less </code> ".
4389
4391
4390
4392
<li><p> If <var> request</var> 's <a for=request>method</a> is "<code> GET</code> " and
4391
4393
<var> request</var> 's <a for=request>destination</a> is "document", then return
4392
- "<code> LaxOrLess </code> ".
4394
+ "<code> lax-or-less </code> ".
4393
4395
4394
4396
<li><p> If <var> request</var> 's <a for=request>client</a>' s
4395
- <a for=environment>has cross-site ancestor</a> is true then return "<code> UnsetOrLess </code> ".
4397
+ <a for=environment>has cross-site ancestor</a> is true, then return "<code> unset-or-less </code> ".
4396
4398
4397
- <li><p> If <var> request</var> 's <a for=request>redirect-taint</a> is "<code> cross-site</code> ",
4398
- then return "<code> UnsetOrLess </code> ".
4399
+ <li><p> If <var> request</var> 's <a for=request>redirect-taint</a> is "<code> cross-site</code> ", then
4400
+ return "<code> unset-or-less </code> ".
4399
4401
4400
- <li><p> Return "<code> StrictOrLess </code> ".
4402
+ <li><p> Return "<code> strict-or-less </code> ".
4401
4403
</ol>
4402
4404
</div>
4403
4405
0 commit comments