Subject: Re: RFC1933 IPv4 mapped address
To: Andrew Brown <atatat@atatdot.net>
From: Matt Thomas <matt@3am-software.com>
List: tech-net
Date: 12/19/1999 23:22:27
At 08:55 PM 12/19/99 , itojun@iijlab.net wrote:

> >>Well, standards are standards but I don't like to have it on by
> >>default as to me it doesn't follow the rule `of least suprise';
> >>It makes a bind on INET6 get fuzzy semantics, as application
> >>programmer you may think you're accepting only real INET6 connections
> >>but you have no way of telling whether you get IPv4 connections in
> >>disguise too.
> >
> >if you're doing a bind to an INET6 socket and using an appropriately
> >sized sockaddr in the accept call, can't you just check the ipv6
> >address in the resulting sockaddr via the IN6_IS_ADDR_V4MAPPED() macro
> >(from rfc2133, and superceded by rfc2553)?

But you don't want the connections to match the listening socket at all
so the connecting system gets ECONNREFUSED and not an arbitrarily closed
socket.

-- 
Matt Thomas               Internet:   matt@3am-software.com
3am Software Foundry      WWW URL:    http://www.3am-software.com/bio/matt/
Cupertino, CA             Disclaimer: I avow all knowledge of this message