]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
auth: Check that an ENT is properly removed by an UPDATE
authorRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 17 May 2019 13:09:50 +0000 (15:09 +0200)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 17 May 2019 15:20:06 +0000 (17:20 +0200)
regression-tests/tests/1dyndns-cname-and-other-data/command
regression-tests/tests/1dyndns-cname-and-other-data/expected_result

index 32ef5676e0f3201472bf25a3beec41799ee5c1ba..39f77560b94d4ae9b4bb13e2b8bd6982994316c5 100755 (executable)
@@ -19,6 +19,15 @@ echo '* check that indeed nothing was added'
 cleandig $RECORDNAME A hidesoadetails
 cleandig $RECORDNAME CNAME hidesoadetails
 
+echo '* Add a record that will result in an ENT being inserted at the upcoming CNAME'
+cleannsupdate <<!
+server $nameserver $port
+zone test.dyndns
+update add sub.$RECORDNAME. 3600 A 192.0.2.1
+send
+answer
+!
+
 echo '* Add a CNAME'
 cleannsupdate <<!
 server $nameserver $port
@@ -28,6 +37,15 @@ send
 answer
 !
 
+echo '* Delete the now useless record inserted to get an ENT there'
+cleannsupdate <<!
+server $nameserver $port
+zone test.dyndns
+update delete sub.$RECORDNAME. 3600 A 192.0.2.1
+send
+answer
+!
+
 echo '* Attempt to add an A record (should be REFUSED)'
 cleannsupdate <<!
 server $nameserver $port
index 6cee2c490079cb209499d8576ba1825fcaf1f9c8..371bdf9fdecf625e3b039fd9b98832b62bea7253 100644 (file)
@@ -16,6 +16,13 @@ Reply to question for qname='cname-and-other.test.dyndns.', qtype=A
 1      test.dyndns.    IN      SOA     3600    ns1.test.dyndns. ahu.example.dyndns. [serial] 28800 7200 604800 86400
 Rcode: 3 (Non-Existent domain), RD: 0, QR: 1, TC: 0, AA: 1, opcode: 0
 Reply to question for qname='cname-and-other.test.dyndns.', qtype=CNAME
+* Add a record that will result in an ENT being inserted at the upcoming CNAME
+Answer:
+;; ->>HEADER<<- opcode: UPDATE, status: NOERROR, id: [id]
+;; flags: qr aa; ZONE: 1, PREREQ: 0, UPDATE: 0, ADDITIONAL: 0
+;; ZONE SECTION:
+;test.dyndns.                  IN      SOA
+
 * Add a CNAME
 Answer:
 ;; ->>HEADER<<- opcode: UPDATE, status: NOERROR, id: [id]
@@ -23,6 +30,13 @@ Answer:
 ;; ZONE SECTION:
 ;test.dyndns.                  IN      SOA
 
+* Delete the now useless record inserted to get an ENT there
+Answer:
+;; ->>HEADER<<- opcode: UPDATE, status: NOERROR, id: [id]
+;; flags: qr aa; ZONE: 1, PREREQ: 0, UPDATE: 0, ADDITIONAL: 0
+;; ZONE SECTION:
+;test.dyndns.                  IN      SOA
+
 * Attempt to add an A record (should be REFUSED)
 Answer:
 ;; ->>HEADER<<- opcode: UPDATE, status: REFUSED, id: [id]