You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Incorrect ipaddress.ip_address.reverse_pointer with improved textual representation of IPv4-mapped IPv6 addresses #123409
I'm seeing strange results with python 3.13 with the ipaddress.ip_address.reverse_pointer attribute with the new improved textual representation of IPv4-mapped IPv6 addresses:
I'm not sure which one is more valid or if a pointer record is even relevant in the context of mapped addresses. The original way seems more correct to me if nothing for the fact that there are strange extra dots in the new output.
You're welcome! (I hope that I didn't misread the RFC because it doesn't tell anything about mapped addresses; however I assumed that we first map IPv4 to IPv6 before taking its reverse pointer, which is what was being done in 3.12.5)
Activity
picnixz commentedon Aug 28, 2024
I think there is indeed an issue with the reverse pointer of IPv6. It does not match the RFC. I'll provide a patch.
opavlyuk commentedon Aug 28, 2024
@kellyjonbrazil Godd catch! Thank you for logging that, and I apologize for missing it during testing.
@picnixz thank you for taking care of this!
gh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped addresses (
pythongh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped ad…
[3.13] gh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped a…
encukou commentedon Sep 5, 2024
Thanks @kellyjonbrazil for the report and @picnixz for the patch!
picnixz commentedon Sep 5, 2024
You're welcome! (I hope that I didn't misread the RFC because it doesn't tell anything about mapped addresses; however I assumed that we first map IPv4 to IPv6 before taking its reverse pointer, which is what was being done in 3.12.5)
pythongh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped ad…
pythongh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped ad…
pythongh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped ad…
pythongh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped ad…
[3.10] gh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped a…
[3.11] gh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped a…
[3.12] gh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped a…
[3.9] gh-123409: fix `IPv6Address.reverse_pointer` for IPv4-mapped ad…