Clone of https://github.com/miekg/dns