Subject: PR/27286 CVS commit: [netbsd-2] src/sys/net
To: None <kern-bug-people@netbsd.org, gnats-admin@netbsd.org,>
From: Jeff Rizzo <riz@netbsd.org>
List: netbsd-bugs
Date: 05/18/2005 18:29:01
The following reply was made to PR kern/27286; it has been noted by GNATS.

From: Jeff Rizzo <riz@netbsd.org>
To: gnats-bugs@netbsd.org
Cc: 
Subject: PR/27286 CVS commit: [netbsd-2] src/sys/net
Date: Wed, 18 May 2005 18:28:39 +0000 (UTC)

 Module Name:	src
 Committed By:	riz
 Date:		Wed May 18 18:28:39 UTC 2005
 
 Modified Files:
 	src/sys/net [netbsd-2]: rtsock.c
 
 Log Message:
 Pull up revision 1.72 via patch (requested by christos in ticket #961):
 PR/27286: Tom Ivar Helbekkmo: Allow RTM_GET to work with RTA_IFA|RTA_IFP set.
 Quiting Tom: The problem is the special case of an RTM_GET message
 that wants interface information included in the response, and
 therefore include the RTA_IFA or RTA_IFP (or both) flags in the
 bitmask that says what addresses are supplied in the message.  For
 the RTM_GET message, it doesn't make sense to supply addresses
 other than the one you're asking about, so those two other bits
 are, in that specific case, overloaded with this meaning.
 There is code in sys/net/rtsock.c to handle the case, but at some
 time, extra sanity checking of the received message was added, that
 failed to take this possibility into account.
 The patch, is needed for the Asterisk software PBX to work properly
 when it has multiple interfaces active: it needs to ask the kernel
 for the IP address of the interface that will be used to communicate
 with a given host.
 
 
 To generate a diff of this commit:
 cvs rdiff -r1.67.2.1 -r1.67.2.1.2.1 src/sys/net/rtsock.c
 
 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.