From 4204efb459963142d19a0d054f922e6c89372688 Mon Sep 17 00:00:00 2001 From: Otto Moerbeek Date: Wed, 22 Mar 2023 11:04:13 +0100 Subject: [PATCH] Continue processing records after OPT in ageDNSPacket() --- pdns/dnsparser.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pdns/dnsparser.cc b/pdns/dnsparser.cc index e726ef24e2..87356a9427 100644 --- a/pdns/dnsparser.cc +++ b/pdns/dnsparser.cc @@ -949,11 +949,11 @@ void ageDNSPacket(char* packet, size_t length, uint32_t seconds, const dnsheader /* class */ dpm.skipBytes(2); - if (dnstype == QType::OPT) { // not aging that one with a stick - break; + if (dnstype != QType::OPT) { // not aging that one with a stick + dpm.decreaseAndSkip32BitInt(seconds); + } else { + dpm.skipBytes(4); } - - dpm.decreaseAndSkip32BitInt(seconds); dpm.skipRData(); } } -- 2.47.2