It appears that zonefiles that use lowercase class and RR type keywords are causing DNS::Zone.load to choke and throw an exception:
#! /usr/bin/ruby
require('rubygems')
require('dns/zone')
zdata = <<EOT
$ttl 3600
$origin dnszone.example.com.
@ in soa ns1.example.com. hostmaster.dnszone.example.com. (
2012052400 ; serial
345600 ; refresh
3600 ; retry
604800 ; expire
3600 ; ttl
)
EOT
DNS::Zone.load(zdata)
=> RuntimeError: Unknown or unsupported RR Type
from /usr/local/share/gems/gems/dns-zone-0.3.1/lib/dns/zone/rr.rb:56:in `load'
from /usr/local/share/gems/gems/dns-zone-0.3.1/lib/dns/zone.rb:105:in `block in load'
from /usr/local/share/gems/gems/dns-zone-0.3.1/lib/dns/zone.rb:91:in `each'
from /usr/local/share/gems/gems/dns-zone-0.3.1/lib/dns/zone.rb:91:in `load'
There is no requirement that the keywords be uppercase.
I'll see if I can work up a patch for this.
It appears that zonefiles that use lowercase class and RR type keywords are causing
DNS::Zone.loadto choke and throw an exception:There is no requirement that the keywords be uppercase.
I'll see if I can work up a patch for this.