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

Unexpected empty string returned from ToPunycode #490

Closed
RBeaudoin opened this issue May 22, 2017 · 6 comments
Closed

Unexpected empty string returned from ToPunycode #490

RBeaudoin opened this issue May 22, 2017 · 6 comments

Comments

@RBeaudoin
Copy link

When I execute the following:

func main() {
 fmt.Println(idn.ToPunycode("❤.rust-lang.org"))
}

It prints the empty string. I would expect the ToPunycode method to return xn--qei.rust-lang.org

@rafaeljusto
Copy link
Contributor

rafaeljusto commented May 23, 2017

The domain ❤.rust-lang.org did not convert also in the Verisign IDN Tool. I got it converted in Punycoder website. The code point 10084 (U+2764 - ) is disallowed in this library due to CURVED STEM PARAGRAPH SIGN ORNAMENT..HEAVY W (reference) and follows RFC 5892 - Appendix B.1.

@RBeaudoin
Copy link
Author

Thanks @rafaeljusto

This seems to be a code point that is allowed in some implementations, but not others. The RFC does seem to clearly indicate that it is not allowed.

@miekg
Copy link
Owner

miekg commented May 23, 2017 via email

@andrewtj
Copy link
Collaborator

@RBeaudoin are you satisfied with @rafaeljusto's explanation or would you like to start a conversation about (potentially) adding additional API?

@RBeaudoin
Copy link
Author

@andrewtj yes, thank you. At Heroku we had to switch to another library because Let's Encrypt supports issuing certs for emoji domains, and we do pre-validation.

I completely understand it's not in the spec though, and appreciate the explanation.

@miekg
Copy link
Owner

miekg commented Nov 24, 2017

#584 (removes our implementation of idn)

@miekg miekg closed this as completed Nov 24, 2017
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

4 participants