Closed
Bug 1745604
Opened 4 years ago
Closed 4 years ago
Some chars are not encoded in the hostname got from an URL object
Categories
(Core :: Networking, defect)
Core
Networking
Tracking
()
RESOLVED
INVALID
| Tracking | Status | |
|---|---|---|
| firefox97 | --- | affected |
People
(Reporter: calixte, Unassigned)
Details
For example:
new URL("http://www.${.com").hostname
returns "www.${.com" when the same in Chrome returns "www.%24%7B.com".
After reading the specs, my feeling is that Chrome is correct here.
In section-3.2.2, the host can be a reg-name and this one is defined by
reg-name = *( unreserved / pct-encoded / sub-delims )
and these 3 possibilities don't include chars "$" or "{" which should be then encoded with a percent.
| Reporter | ||
Comment 1•4 years ago
|
||
I misread, in fact "$" should be allowed.
Comment 2•4 years ago
|
||
We currently parse it just like the reference URL parser for the URL standard.
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → INVALID
You need to log in
before you can comment on or make changes to this bug.
Description
•