[whatwg/url] Can a registrable domain or public suffix have a trailing dot? (Issue #693)

Normally `example.com.` and `example.com` are considered distinct origins, but https://github.com/publicsuffix/list/wiki/Format#formal-algorithm suggests

> A domain or rule can be split into a list of labels using the separator "." (dot). The separator is not part of any of the labels. Empty labels are not permitted, meaning that leading and trailing dots are ignored.

they might be considered same-site? That seems wrong to me and I would expect a trailing dot to be preserved as we preserve it everywhere else.

Neither URL nor HTML has trailing dot examples so I'm not sure if we explicitly considered this before.

cc @mikewest @sleevi @valenting @achristensen07 @dnsguru

(If the trailing dot is indeed significant follow-up is needed in at least https://github.com/httpwg/http-extensions/issues/1758 and Fetch's "`localhost`" check, which should then also consider "`localhost.`".)

-- 
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/url/issues/693
You are receiving this because you are subscribed to this thread.

Message ID: <whatwg/url/issues/693@github.com>

Received on Friday, 29 April 2022 08:29:38 UTC