[Baypiggies] Windows Python 2.5.1 IPV6 problems

Pavel Pergamenshchik ppergame at cisco.com
Tue Feb 5 20:21:25 CET 2008


On Sat, 2 Feb 2008 20:52:40 -0800 (PST)
Thomas DiZoglio <tomdiz at yahoo.com> wrote:

> I'm trying to get some IPV6 python code running under
> Windows. I have installed Python 2.5.1 for Windows
> using the binaries from python.org.
> 
> The code works fine under Debian and MacOSX (both
> using Python 2.5)
> 
> I have rebuilt the python binaries from source and set
> ENABLE_IPV6. This didn't help. I have also read about
> not being able to bind to a IPV4 and IPV6 socket. I
> tried setting the setsockopt() call using IPV6_V6ONLY,
> but this is not recognized by the python interpreter.

Works fine here with the binaries from python.org:

Python 2.5.1 (r251:54863, Apr 18 2007, 08:51:08) [MSC v.1310 32 bit
(Intel)] on win32 Type "help", "copyright", "credits" or "license" for
more information.
>>> from socket import *
>>> s=socket(AF_INET6, SOCK_STREAM)
>>> s.connect(('xzrq.net', 22))
>>> s.getpeername()
('2001:470:1f02:252::2', 22, 0, 0)

Are you sure the problem is with your Python installation (why did you
recompile it, anyway?) and not the script you are using?


More information about the Baypiggies mailing list