History log of /seL4-refos-master/libs/libmuslc/src/network/lookup_ipliteral.c
Revision Date Author Comments
# 2a6e1f0f 24-Sep-2015 Rich Felker <dalias@aerifal.cx>

avoid attempting to lookup IP literals as hostnames

previously, __lookup_ipliteral only checked its argument against the
requested address family, so IPv4 literals passed through to
__lookup_name if the caller asked for only IPv6 results, and likewise
for IPv6 literals when the caller asked for only IPv4. this resulted
in spurious DNS lookups that reportedly even succeeded with some
nameservers.

now, __lookup_ipliteral attempts to parse its argument as both IPv4
and IPv6, and returns an error (to stop further search) rather than 0
(no results yet) if the form of the argument mismatches the requested
address family.

based on patch by Julien Ramseier.


# cb1c88d4 11-Sep-2015 Timo Teräs <timo.teras@iki.fi>

fix uninitialized scopeid in lookups from hosts file and ip literals


# 7e222f46 05-Jun-2014 Rich Felker <dalias@aerifal.cx>

fix missing function declarations in refactored ip literal parsing code


# 01dc3f4f 04-Jun-2014 Rich Felker <dalias@aerifal.cx>

add support for reverse name lookups from hosts file to getnameinfo

this also affects the legacy gethostbyaddr family, which uses
getnameinfo as its backend.

some other minor changes associated with the refactoring of source
files are also made; in particular, the resolv.conf parser now uses
the same code that's used elsewhere to handle ip literals, so as a
side effect it can now accept a scope id for nameserver addressed with
link-local scope.