]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
3452. [bug] Accept duplicate singlton records. [RT #32329]
authorMark Andrews <marka@isc.org>
Mon, 7 Jan 2013 23:58:42 +0000 (10:58 +1100)
committerMark Andrews <marka@isc.org>
Mon, 7 Jan 2013 23:58:42 +0000 (10:58 +1100)
CHANGES
lib/dns/message.c

diff --git a/CHANGES b/CHANGES
index 555944c1ae129cb45e1fc13894e9297043a15d82..e0e40fab045321863c222c0d5f2f3a981bda58e1 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,5 @@
+3452.  [bug]           Accept duplicate singlton records. [RT #32329]
+
 3451.  [port]          Increase per thread stack size from 64K to 1M.
                        [RT #32230]
 
index ef0bf6591b5de962685c26d11ef70b547adfcf2b..cd6320772ceb53b214365778427129b48e27a00a 100644 (file)
@@ -1441,8 +1441,15 @@ getsection(isc_buffer_t *source, dns_message_t *msg, dns_decompress_t *dctx,
                 * the opcode is an update, or the type search is skipped.
                 */
                if (result == ISC_R_SUCCESS) {
-                       if (dns_rdatatype_issingleton(rdtype))
-                               DO_FORMERR;
+                       if (dns_rdatatype_issingleton(rdtype)) {
+                               dns_rdata_t *first;
+                               dns_rdatalist_fromrdataset(rdataset,
+                                                          &rdatalist);
+                               first = ISC_LIST_HEAD(rdatalist->rdata);
+                               INSIST(first != NULL);
+                               if (dns_rdata_compare(rdata, first) != 0)
+                                       DO_FORMERR;
+                       }
                }
 
                if (result == ISC_R_NOTFOUND) {