Bug 928895 - python-dns is not able to parse zones used for testing BIND9
Summary: python-dns is not able to parse zones used for testing BIND9
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: python-dns
Version: 17
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jeffrey C. Ollie
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-03-28 17:01 UTC by Petr Spacek
Modified: 2013-03-28 20:17 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2013-03-28 20:17:14 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
zone generator (6.75 KB, text/plain)
2013-03-28 17:01 UTC, Petr Spacek
no flags Details
unparsable zone file with MG record (5.64 KB, text/plain)
2013-03-28 17:03 UTC, Petr Spacek
no flags Details
unparsable zone file with KEY record (2.07 KB, text/plain)
2013-03-28 17:56 UTC, Petr Spacek
no flags Details

Description Petr Spacek 2013-03-28 17:01:20 UTC
Created attachment 717736 [details]
zone generator

Description of problem:
BIND9 test suite contains a script for generating zone files. Zones from this script are valid (BIND is able to load and serve them correctly), but python-dns blows up.


Version-Release number of selected component (if applicable):
python-dns-1.10.0-1.fc17.noarch

How reproducible:
100 %


Steps to Reproduce:
1. Generate a zone with attached script (script came from BIND 9 test suite):
$ genzone.sh 2 3 4 > master2.db

2. Try to load the zone with following Python snippet:
import dns.zone
dns.zone.from_file('master2.db', origin='master2.')

  
Actual results:
Traceback (most recent call last):
  File "test.py", line 2, in <module>
    dns.zone.from_file('master2.db', origin='master2.')
  File "/usr/lib/python2.7/site-packages/dns/zone.py", line 814, in from_file
    filename, allow_include, check_origin)
  File "/usr/lib/python2.7/site-packages/dns/zone.py", line 761, in from_text
    reader.read()
  File "/usr/lib/python2.7/site-packages/dns/zone.py", line 715, in read
    raise dns.exception.SyntaxError("%s:%d: %s" % (filename, line_number, detail))
dns.exception.SyntaxError: master2.db:41: generic rdata does not start with \#


Expected results:
Zone is parsed correctly.

Additional info:
line 41 from generated zone:
mb02                    MG      .

Comment 1 Petr Spacek 2013-03-28 17:03:47 UTC
Created attachment 717738 [details]
unparsable zone file with MG record

Comment 2 Petr Spacek 2013-03-28 17:56:55 UTC
Created attachment 717750 [details]
unparsable zone file with KEY record

I hit exactly same problem with KEY records. Attached zone was generated by BIND scripts in bind-9.9.2-P1/bin/tests/system/tsiggss/ns1.

Comment 3 Jeffrey C. Ollie 2013-03-28 20:17:14 UTC
This is definitely something that you should work with upstream to fix.  Once they have released a new version, I'd be happy to update the package.


Note You need to log in before you can comment on or make changes to this bug.