bug-inetutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug-inetutils] Traceroute in inet6-preferred environments.


From: Mats Erik Andersson
Subject: [bug-inetutils] Traceroute in inet6-preferred environments.
Date: Wed, 3 Nov 2010 15:20:55 +0100
User-agent: Mutt/1.5.18 (2008-05-17)

Let me suggest a first straightforward change to `traceroute'
that will be useful also for an upcoming IPv6 migration, but
is already now important to protect against "RES_OPTIONS=inet6".

To understand this matter, you could try this invokation

    sudo    RES_OPTIONS=inet6  ./src/traceroute www.google.com

on the present executable.

The failure is due eto the use of gethostbyname(3), which gets
severely confused by AF_INET6 answers.

The submitted patch resolves this calamity by a standard migration
to getaddrinfo(3) and getnameinfo(3). There is no step undertaken
towards IPv6 yet, only a guard against unusual but legitimate system
setups.

Tested on GNU/Linux, OpenBSD, and FreeBSD. The service `traceroute'
is now immune against the above call.


Best regards,
Mats

Attachment: 0001-src-traceroute-Protect-against-resolver-option-inet6.patch
Description: Text Data

Attachment: signature.asc
Description: Digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]