From 713060f54dd7da6aa18fdd57e2cf5f6603ddd6d0 Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Fri, 10 Apr 2026 10:26:14 +1000 Subject: [PATCH] Properly handle rpz name to long wildcard expansion Previously a self referential CNAME and the original address record were returned. We now return a YXDOMAIN response. (cherry picked from commit cfc4c4f69870ce492deaaa429453563d1621ded3) --- lib/ns/query.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/ns/query.c b/lib/ns/query.c index f7f0623713..609ef50739 100644 --- a/lib/ns/query.c +++ b/lib/ns/query.c @@ -7575,7 +7575,8 @@ query_rpzcname(query_ctx_t *qctx, dns_name_t *cname) { qctx->fname, NULL); if (result == DNS_R_NAMETOOLONG) { client->message->rcode = dns_rcode_yxdomain; - } else if (result != ISC_R_SUCCESS) { + } + if (result != ISC_R_SUCCESS) { return result; } } else {