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

HOST accepts comma chars #198

Closed
nsoufr opened this issue May 22, 2015 · 3 comments
Closed

HOST accepts comma chars #198

nsoufr opened this issue May 22, 2015 · 3 comments

Comments

@nsoufr
Copy link

nsoufr commented May 22, 2015

I noticed that Addressable::URI.parse do not take 'http://www,google.com' as invalid, behavior which I was expecting.

Is that correct?

Thanks in advance!

@sporkmonger
Copy link
Owner

Yup, according to the RFC (but probably not DNS), that's correct. Addressable does not currently consider DNS in validating a URI, something that was a core motivation for writing Addressable in the first place. Per the comment on twingly/twingly-uri#74, I'm considering a sane? method that would consider things like valid DNS hostnames.

@dentarg
Copy link
Collaborator

dentarg commented Jun 15, 2016

Per the comment on twingly/twingly-uri#74

Just to connect the issues (because of the typo above), here is a link to the comment: twingly/twingly-url#74 (comment)

@sporkmonger
Copy link
Owner

This handling was updated in f032606, but since commas are in sub-delims, they're still valid in a hostname. Closing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants