I'm proud to announce the first public relase of IPy.
IPy is a Python module for handling IPv4 and IPv6 addresses and networks in a fashion similar to Perl's Net::IP and related modules. The IP class allows a programmer to comfortably parse and handle most notations in use for IPv4 and IPv6 addresses and networks. It can detect about a dozen different ways of expressing IP addresses and networks, parse them, and distinguish between IPv4 and IPv6 addresses. IPy comes with a lot of docstrings containing doctest-proofed examples, a distutils-based setup script, and an extensive test script.
It can be found http://c0re.jp/c0de/IPy/
IPy allows you to handle IP Networks in a highly python integrated way like this:
>>> ip = IP('127.0.0.0/30') >>> for x in ip: ... print x ... 127.0.0.0 127.0.0.1 127.0.0.2 127.0.0.3 >>> ip2 = IP('0x7f000000/30') >>> ip == ip2 1