This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author xZise
Recipients xZise
Date 2014-08-27.09:33:26
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1409132006.4.0.222962839937.issue22282@psf.upfronthosting.co.za>
In-reply-to
Content
The ipaddress module accepts IPv6 addresses if the IPv4 address is formatted as an octal number, but http://tools.ietf.org/html/rfc3986#section-3.2.2 doesn't allow leading zeroes in the IPv4 address.

This is the current behaviour (in 3.4.1):

>>> ipaddress.ip_address("::1.0.0.00")
IPv6Address('::100:0')

Expected:

>>> ipaddress.ip_address("::1.0.0.00")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "3.4.1/lib/python3.4/ipaddress.py", line 54, in ip_address
    address)
ValueError: '::1.0.0.00' does not appear to be an IPv4 or IPv6 address

Because I didn't know it better, I first tried to patch the backport but this might be still applicable the official code: https://github.com/phihag/ipaddress/pull/12
History
Date User Action Args
2014-08-27 09:33:26xZisesetrecipients: + xZise
2014-08-27 09:33:26xZisesetmessageid: <1409132006.4.0.222962839937.issue22282@psf.upfronthosting.co.za>
2014-08-27 09:33:26xZiselinkissue22282 messages
2014-08-27 09:33:26xZisecreate