LWN.net Logo

Facts are ignored as usual...

Facts are ignored as usual...

Posted Jan 28, 2011 1:18 UTC (Fri) by cesarb (subscriber, #6266)
In reply to: Facts are ignored as usual... by bojan
Parent article: LCA: IP address exhaustion and the end of the open net

> So, tell me, how does my software vendor enable "32bit syscall emulation" on my IPv6 stack to use my IPv4 address there?

int on = 0;
setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on));

This allows you to use a single IPv6 socket for both IPv6 and IPv4 transparently (IPv4 addresses show as IPv4-mapped IPv6 addresses).


(Log in to post comments)

Facts are ignored as usual...

Posted Jan 28, 2011 1:28 UTC (Fri) by bojan (subscriber, #14302) [Link]

Oh, wow! Why don't you show this to the IPv6 working group (or whoever is not in charge of the transition). I'm sure they'd like to fix the Internet with this 2 line patch. ;-)

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds