Bug 122039 - [ip6] IP_RECVDSTADDR not IPv6 compatible
Summary: [ip6] IP_RECVDSTADDR not IPv6 compatible
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: 8.0-CURRENT
Hardware: Any Any
: Normal Affects Only Me
Assignee: George V. Neville-Neil
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-03-24 08:20 UTC by Poul-Henning Kamp
Modified: 2009-01-31 15:02 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Poul-Henning Kamp 2008-03-24 08:20:00 UTC
	If one sets IP_RECVDSTADDR on a socket (see ip(4)), it
	returns a "struct in_addr" in the cmsg along with the
	packets.

	That is not IPv6 compatible.

	Similar issues may hold for IP_SENDSRCADDR
Comment 1 Poul-Henning Kamp freebsd_committer freebsd_triage 2008-03-24 08:23:20 UTC
Responsible Changed
From-To: freebsd-bugs->gnn

Over to gnn@ per request
Comment 2 Bjoern A. Zeeb freebsd_committer freebsd_triage 2008-03-24 13:04:09 UTC
Hi,

Do you want to use IP_RECVDSTADDR on an AF_INET6 socket?

The proper interface for an IPv6 socket is defined in RFC 3542
[ http://www.rfc-editor.org/rfc/rfc3542.txt ].
See Paragraph 6. Packet Information for what you are trying to achive.

If you mean that it is possible to use IP_RECVDSTADDR on an IPv6
socket that might sound bogus. I am unsure what the correct semantics
for an v4 mapped v6 address would be but that might be a reason to
permit this on a limited number of sockets.

If we are trying to return an IPv6 address when IP_RECVDSTADDR was set
on an IPv6 socket, that sounds like a bug and should be fixed.

Unfortunately your PR is not very precise about your actual problem.
I guess gnn knows;-)

-- 
Bjoern A. Zeeb                                 bzeeb at Zabbadoz dot NeT
Software is harder than hardware  so better get it right the first time.
Comment 3 Volker Werth freebsd_committer freebsd_triage 2009-01-31 14:44:58 UTC
State Changed
From-To: open->closed

closing this PR in favour of kern/118880 - content migrated