Hello Michael, On 02/03/2014 02:41 PM, m...@tls.msk.ru wrote: > 3 feb 2014 г. 17:08:31 GMT+04:00, IMAP List Administration <li...@y42.org> > wrote: > > > >Indeed, the problem was being caused by bug(s) in the OpenBSD > >implementation of > >gethostbyaddr(). > > Care to give some more information about those bug(s) please? apparently a large portion the DNS resolver was rewritten for OpenBSD 5.4. In the changes for 5.4 one can find a number of bullet-items referring to the "new resolver". I do not know why it was re-implemented.
Apparently the list of test-cases the author(s) used was not complete. In particular, gethostbyaddr() would deliver a correct result for a "trivial" query, i.e., if an address had a single PTR record. But gethostbyaddr() would fail for 2 types of non-trivial configurations: 1) if a CNAME record had to be looked up in order to be able to look up the PTR record (a mechanism used by ISPs to delegate in-arpa address-spaces that are usually smaller than a class C subnet -- RFC2317). 2) when trying to look up addresses with several PTR records. Case 1 was caused by not allowing a slash ("/") character in names. There is a patch available (look at the OpenBSD "tech" list) which seems to fix the problem. cheers, Rob Urban