Sunday, March 25, 2007
MaraDNS snaphost: MaraDNS now has BIND zone file support
MaraDNS 2007.03.25 released
OK, I finally have a usable bind2csv2 parser. This parser has only undergone the most basic of testing.
What this parser is is a script to convert BIND zone files in to MaraDNS 1.3 compatible csv2 zone files. The script is written in Python, so people who need BIND zone file support will need Python on their system. The program was written in Python 2.2.3, and hopefully will work with more recent versions of Python.
The name of the script is bind2csv2.py, and it is in the tools/ directory.
This script is not complete yet. In particular, the $ORIGIN, $TTL, and $READ directives have not been implemented yet. Note that the csv2 parser has has support for these directives since last summer; it's very simple to add these directives to the python script.
Currently, the bins2csv2.py script has support for the following RR types:
A, NS, CNAME, PTR, SOA, MX, AAAA, SRV, TXT, SPF, HINFO, MB, MD, MF, MG, MR, MINFO, MFSDB, RP, X25, ISDN, RT, and GPOS. There are stubs for supporting WKS, NAP, PX, and LOC, but the code for these RRs has not been written yet.
If a TXT field uses \xxx excape sequences, these will become literal '\xxx' sequences in the csv2 zone file.
To use the script, run bindtcsv2 thusly:
bind2csv2.py -c zonefile
Where zonefile is the file you wish to convert from a BIND to a CSV2 zone file. The python script will output a file with a name like zonefile.csv2, which (hopefully) is a csc2 zone file MaraDNS 1.3 can parse.
If zonefile.csv2 already exists, bind2csv2.py will erase and replace the already existing zonefile.
I am now asking for people to help me test this script by sending me BIND zone files to test parsing with.