Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IPv4 with non-ASCII dots #287

Closed
elliotwutingfeng opened this issue May 18, 2023 · 3 comments · Fixed by #292
Closed

IPv4 with non-ASCII dots #287

elliotwutingfeng opened this issue May 18, 2023 · 3 comments · Fixed by #292

Comments

@elliotwutingfeng
Copy link
Contributor

Should IPv4 addresses with non-ASCII dots be accepted?

Example: http://127\u30020\uff610\u002e1/foo/bar

@john-kurkowski
Copy link
Owner

Interesting question! It's never come up. So I lean toward not? Are you encountering an issue?

On the other hand, implementing it wouldn't be a huge burden. It would be symmetrical with other dot-splitting code in the project.

@elliotwutingfeng
Copy link
Contributor Author

elliotwutingfeng commented May 18, 2023

Chrome and Firefox addressbars both automatically convert unicode dots to ascii dots for IPv4 addresses.

On a sidenote, for IPv6 addresses with a trailing IPv4 address, like [aBcD:ef01:2345:6789:aBcD:ef01:127.0。0。1], Chrome automatically converts the dots, but not Firefox.

@john-kurkowski
Copy link
Owner

Ok, I see the usability benefit. I'm open to a fix for this!

john-kurkowski added a commit that referenced this issue May 26, 2023
…th unicode dots. (#292)

- IPv4 addresses with unicode dots are now recognized. Closes #287
- IPv4 addresses must have 4 decimal octets. Closes #290

---------

Co-authored-by: John Kurkowski <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants