dns-parser icon indicating copy to clipboard operation
dns-parser copied to clipboard

label is not ascii errors with hostnames containing utf8 characters

Open ishanjain28 opened this issue 2 years ago • 1 comments

This library here https://github.com/tailhook/dns-parser/blob/191266705b30feabe9fbf9289b4cb4da0ea2be31/src/name.rs#L75-L77 returns a LabelIsNotAscii error when it encounters queries or answers with label or hostnames containing utf8 characters.

With "normal" DNS queries, utf8 characters are converted to puny code. Multicast DNS queries have the exact same structure except they allow ascii or utf8 characters.[1]

I don't know if it's within the scope of this project. If it is, I believe that line should be changed to allow any utf8 encoded string.

[1] https://datatracker.ietf.org/doc/html/rfc6762#appendix-F

ishanjain28 avatar Nov 17 '23 17:11 ishanjain28

The same question!

2024-01-31 18-21-29屏幕截图

wfeii1980 avatar Jan 31 '24 10:01 wfeii1980