TigerVNC / tigervnc

High performance, multi-platform VNC client and server
https://tigervnc.org
GNU General Public License v2.0
5.24k stars 954 forks source link

IPv6 address in HostsFile not working #1389

Open skrzyp1 opened 2 years ago

skrzyp1 commented 2 years ago

Describe the bug When IPv6 address is in HostsFile Server quits after first attempted connection with log line: Main: unable to resolve host by name: Name or service not known

To Reproduce Steps to reproduce the behavior: Create HostsFile containing two lines: +IPv6 address - run x0vncserver with -HostsFile option

Try to connect.

Expected behavior Server parses IPv6 address and does not quit.

Server (please complete the following information):

Additional context I think this might be caused by too short readline here 32 chars is to little for IPv6 address (although i don't know if this is the only problem with parsing). Log line might be coming from here or here

--- Want to back this issue? **[Post a bounty on it!](https://app.bountysource.com/issues/108361143-ipv6-address-in-hostsfile-not-working?utm_campaign=plugin&utm_content=tracker%2F3557444&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://app.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F3557444&utm_medium=issues&utm_source=github).
CendioOssman commented 2 years ago

The parser should handle IPv6, but that buffer does indeed seem to be way too small.