MX with 'empty' name breaks bindbackend AXFR out #1243

Closed
zeha opened this Issue Jan 28, 2014 · 4 comments

Projects

None yet

3 participants

@zeha
Collaborator
zeha commented Jan 28, 2014
$TTL 3600
$ORIGIN test.com.
@               IN      SOA     ns1.test.com.   ahu.example.com. (  2005092501
                        8H ; refresh
                        2H ; retry
                        1W ; expire
                        1D ; default_ttl
                        )

@                       IN      NS      ns1
@                       IN      NS      ns2
@                       IN      MX      10      smtp-servers.example.com.
@                       IN      MX      15      smtp-servers
@                       IN      MX      30      .

Breaks AXFR out:

Jan 28 12:27:55 Initiating transfer of 'test.com' from remote '127.0.0.1:5455'
Jan 28 12:27:55 AXFR of domain 'test.com' initiated by 127.0.0.1
Jan 28 12:27:55 AXFR of domain 'test.com' allowed: client IP 127.0.0.1 is in allow-axfr-ips
Jan 28 12:27:55 AXFR started for 'test.com'
Jan 28 12:27:55 Exception: Parsing record content: missing field at the end of record content '30 '
Jan 28 12:27:55 TCP Connection Thread died because of STL error: Parsing record content: missing field at the end of record content '30 '
Jan 28 12:27:55 Unable to AXFR zone 'test.com' from remote '127.0.0.1:5455' (resolver): Remote nameserver closed TCP connection
Jan 28 12:27:55 Aborting possible open transaction for domain 'test.com' AXFR
Jan 28 12:27:55 Got a signal 11, attempting to print trace: 
Jan 28 12:27:55 ../pdns/pdns_server() [0x6fd0cd]
Jan 28 12:27:55 /lib/x86_64-linux-gnu/libc.so.6(+0x35250) [0x7fc49d277250]
Jan 28 12:27:55 ../pdns/pdns_server(_ZN12Bind2Backend16abortTransactionEv+0x3e) [0x5ec54e]
Jan 28 12:27:55 ../pdns/pdns_server(_ZN17CommunicatorClass4suckERKSsS1_+0x6778) [0x742a98]
Jan 28 12:27:55 ../pdns/pdns_server(_ZN17CommunicatorClass19retrievalLoopThreadEv+0x12c) [0x75d21c]
Jan 28 12:27:55 ../pdns/pdns_server(_ZN17CommunicatorClass20retrieveLaunchhelperEPv+0x15) [0x75e7c5]
Jan 28 12:27:55 /lib/x86_64-linux-gnu/libpthread.so.0(+0x7e0e) [0x7fc49d5f5e0e]
Jan 28 12:27:55 /lib/x86_64-linux-gnu/libc.so.6(clone+0x6d) [0x7fc49d32b0fd]
./start-test-stop: line 74:  2244 Aborted                 (core dumped) $RUNWRAPPER $PDNS2 --daemon=no --local-port=$port --socket-dir=./ --no-shuffle --launch=bind --bind-config=./named-slave.conf --slave --send-root-referral --retrieval-threads=1 --config-name=bind-slave --allow-2136-from=127.0.0.0/8 --experimental-rfc2136=yes --cache-ttl=$cachettl --no-config --bind-dnssec-db=./dnssec-slave.sqlite3
@cmouse
Contributor
cmouse commented Jan 28, 2014

Could be due to modules/bindbackend/bindbackend2.cc:211, where we delete d_of without checking if it's NULL or not.

@zeha
Collaborator
zeha commented Jan 28, 2014

Segfault fix in #1246

@cmouse
Contributor
cmouse commented Jan 28, 2014

There are several problems with zoneparser-tng.cc if content is ".". Also it seems that NAPTR might get shot too, but not sure.

@cmouse
Contributor
cmouse commented Jan 28, 2014

This might be related to #1247

@ahupowerdns ahupowerdns added a commit that closed this issue Dec 10, 2014
@ahupowerdns ahupowerdns remove additional layer of trailing . stripping, which broke MX recor…
…ds to the root in the BIND backend. Should close #1243.
a784510
@mind04 mind04 added a commit to mind04/pdns that referenced this issue Dec 22, 2014
@mind04 @mind04 mind04 + mind04 remove additional layer of trailing . stripping, which broke MX recor…
…ds to the root in the BIND backend. Should close #1243.
c16a5a1
@mind04 mind04 added a commit to mind04/pdns that referenced this issue Dec 22, 2014
@ahupowerdns @mind04 ahupowerdns + mind04 remove additional layer of trailing . stripping, which broke MX recor…
…ds to the root in the BIND backend. Should close #1243.
e94c2c4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment