Hello,
The current DNS code checks, when making an A query, whether the name is
in fact an IPv4 address literal. Same for AAAA query with IPv6 address
literal. This is good.
However, nothing prevents A queries for IPv6 address literals or AAAA
queries for IPv4 address literals. This is wrong.
Here's the bug in action (anonymized to protect the innocent):
1.2.3.4 -> 5.6.7.8 SIP 830 Request: ACK
sip:foobar@9.10.11.12:5060;transport=udp
5.6.7.8 -> 1.2.3.4 DNS 72 Standard query AAAA 9.10.11.12
Attached is a simple patch to fix the bug (of which there are three
distinct instances).
Comments?
Simon