Make Unix.{getaddrinfo,getnameinfo} Unicode-aware on Windows#1454
Make Unix.{getaddrinfo,getnameinfo} Unicode-aware on Windows#1454nojb wants to merge 3 commits intoocaml:trunkfrom
Conversation
xavierleroy
left a comment
There was a problem hiding this comment.
The code looks OK to me but I had a rather quick look at it, so it would be good to have a second pair of eyes.
Also, I am still not convinced that Internationalized domain names are a good idea, with all the spoofing they enable.
|
I'm a bit sceptical. Portability: While This means this PR will introduce divergent behaviour between platforms. I'd instead document that IDNs are not supported in the stdlib. There exists an (unreleased) library which does the punycode conversion in pure OCaml. Doing this depends on a unicode library, thus it is not suitable for the stdlib IIUC. OTOH, if divergence between platforms is not an issue, surely this is ok. |
|
IDN stuff needs to be considered very, very carefully when it is integrated because of the security issues that have been mentioned. I note that OCaml's own unicode support is not yet quite complete, which makes it harder to figure out a good solution that works for all of OCaml's platforms. |
|
@hannesm I was not aware of the Technically speaking the divergence is already there today, because it is possible to use Latin-1 (or local code page encoded) hostnames under Windows but only ASCII under Linux (if I understand correctly). I do not have a strong argument for merging apart from coherence with the rest of the |
|
There does not seem to be a consensus for merging this PR, so closing for now. Can always be reopened if needed. |
Unicode host names anyone?