Skip to content
Merged
Changes from 2 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
13 changes: 6 additions & 7 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1086,13 +1086,12 @@ run the following steps:
1. If the [=byte sequence=] [=byte sequence/length=] of |encodedDomain| is greater than the [=cookie/maximum attribute value size=], then return failure.
1. [=list/Append=] \``Domain`\`/|encodedDomain| to |attributes|.
1. If |expires| is given, then [=list/append=] \``Expires`\`/|expires| ([=date serialized=]) to |attributes|.
1. If |path| is not null:
1. If |path| does not start with U+002F (/), then return failure.
1. If |path| is not U+002F (/), and |name|, [=byte-lowercased=], [=byte sequence/starts with=] \``__host-`\`, then return failure.
1. Let |encodedPath| be the result of [=UTF-8 encode|UTF-8 encoding=] |path|.
1. If the [=byte sequence=] [=byte sequence/length=] of |encodedPath| is greater than the [=cookie/maximum attribute value size=], then return failure.
1. [=list/Append=] \``Path`\`/|encodedPath| to |attributes|.
1. Otherwise, [=list/append=] \``Path`\`/ U+002F (/) to |attributes|.
1. If |path| is the empty string, then set |path| to the [=/URL path serializer|URL path serialization=] of |url|.
1. If |path| does not start with U+002F (/), then return failure.
1. If |path| is not U+002F (/), and |name|, [=byte-lowercased=], [=byte sequence/starts with=] \``__host-`\`, then return failure.
1. Let |encodedPath| be the result of [=UTF-8 encode|UTF-8 encoding=] |path|.
1. If the [=byte sequence=] [=byte sequence/length=] of |encodedPath| is greater than the [=cookie/maximum attribute value size=], then return failure.
1. [=list/Append=] \``Path`\`/|encodedPath| to |attributes|.
1. [=list/Append=] \``Secure`\`/\`\` to |attributes|.
1. Switch on |sameSite|:
<dl class=switch>
Expand Down