Bug #7820
closed2.4: dnsmasq can no longer handle punycode, compile time options change?
0%
Description
I've used dnsmasq with a custom hosts file for years, with mappings including the following:
0.0.0.0 r7---sn-vgqsen7z.c.2mdn.net
0.0.0.0 r7---sn-vgqsenee.c.2mdn.net
Up through 2.3.4, this worked fine. Starting in 2.4, it spews errors for each punycode entry when reading in the file:
dnsmasq76042: bad name at /usr/local/etc/dnsmasq.d/hosts.txt line 28011
I found in the changelog for dnsmasq when punycode support was added way back in dnsmasq 2.51:
Add support for internationalised DNS. Non-ASCII charactersin domain names found in /etc/hosts, /etc/ethers and /etc/dnsmasq.conf will be correctly handled by translation topunycode, as specified in RFC3490. This function is onlyavailable if dnsmasq is compiled with internationalisationsupport, and adds a dependency on GNU libidn.
I noticed two differences between dnsmasq in 2.3.4 and 2.4. 2.3.4 ships with dnsmasq 2.76, and 2.4 ships with 2.77. The second and possibly relevant difference is that the compile time options between the two differ in one regard. 2.76 was compiled with "IDN" and 2.77 was compiled with "IDN2."
I'm guessing that this change has something to do with punycode regressing.