Skip to content
Merged
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
13 changes: 8 additions & 5 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -4153,16 +4153,19 @@ Content-Type: application/reports+json
`port-part` matching
</h5>

An <a>ASCII string</a> |input| <dfn export>`port-part` matches</dfn> [=/URL=] |url| if a CSP source expression that
contained the first as a <a grammar>`port-part`</a> could potentially match a URL containing the latter's [=url/port=]
and [=url/scheme=]. For example, "80" <a>`port-part` matches</a> matches http://example.com.
An <a>ASCII string</a> or null |input| <dfn export>`port-part` matches</dfn>
[=/URL=] |url| if a CSP source expression that contained the first as a <a
grammar>`port-part`</a> could potentially match a URL containing the latter's
[=url/port=] and [=url/scheme=]. For example, "80" <a>`port-part` matches</a>
matches http://example.com.

<ol class="algorithm">
1. Assert: |input| is the empty string, "*", or a sequence of <a>ASCII digits</a>.
1. Assert: |input| is null, "*", or a sequence of one or more <a>ASCII digits</a>.

2. If |input| is equal to "*", return "`Matches`".

3. Let |normalizedInput| be null if |input| is the empty string; otherwise |input| interpreted as decimal number.
3. Let |normalizedInput| be null if |input| null; otherwise |input|
interpreted as decimal number.

4. If |normalizedInput| equals |url|'s [=url/port=], return "`Matches`".

Expand Down