Re: AXFR from Bind oddities

DAve <[email protected]> Tue, 13 Apr 2010 08:46:39 -0400
Newsgroups gmane.network.djbdns
Message-ID <[email protected]>
Peter Pentchev wrote:
> On Mon, Apr 12, 2010 at 01:00:41PM -0400, DAve wrote:
>> John Levine wrote:
>>>> Example,
>>>> :djgusa.com:16:Zv\075spf1 <snip>
>>>> Why is the "Z" in "16:Zv"?
>>>>
>>>> :djgusa.com:16:\136spf2.0 <snip>
>>>> Why is the "\136" in "16:\136spf2"?
>>> They're the length byte at the start of the text field.  They
>>> belong there.
>>>
>>> The axfr-get program only knows how to format SOA, NS, CNAME,
>>> PTR, MX, and A records.  Everything else is written out using
>>> the generic colon record type with an explicit record type and
>>> the literal record contents, which for a TXT record includes the
>>> length byte before each text string.
>>>
>>> It wouldn't be hard to add a few lines to axfr-get.c to format
>>> txt records, but there would be no benefit I can see.
>>>
>>> R's,
>>> John
>> As I suspected, I didn't fully understand what was going on 8^)
>> This is a very unique situation for two client's only, so I will change
>> my script to use dig to make the axfr query and Net-DNS-Zonefile to
>> parse the result and load VegaDNS.
> 
> Erm, why not decode the RR lines properly and convert them into
> TXT (') lines, e.g. with something like the attached simple Perl
> utility?  If the attachment should not come through for some reason
> or other, it's available at
> http://devel.ringlet.net/textproc/decodetinydns/decodetinydns.pl

Thank you, I will check it out.

DAve

-- 
"Posterity, you will know how much it cost the present generation to
preserve your freedom.  I hope you will make good use of it.  If you
do not, I shall repent in heaven that ever I took half the pains to
preserve it." John Adams

http://appleseedinfo.org