Skip to content

DNS error passing upstream server flags #7955

@wbsygs

Description

@wbsygs

Prerequisites

Platform (OS and CPU architecture)

Linux, AMD64 (aka x86_64)

Installation

GitHub releases or script from README

Setup

On one machine

AdGuard Home version

v0.107.64

Action

I had the server set up a public DNS service and an intranet DNS server as upstream, confirmed it and then tested the intranet domain using dig.

Expected result

Normally, recursive DNS server flags should return qr, rd, ra.

Actual result

It did return results for the domain I set up.but It turned out that the returned flags had qr, aa, and ra in them, incorrectly keeping the upstream server's flags.I also found out afterward that if it's read from the cache, it will.

Additional information and/or screenshots

$ dig srv.home.arpa

; <<>> DiG 9.18.30-0ubuntu0.24.04.2-Ubuntu <<>> srv.home.arpa
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 40948
;; flags: qr aa rd; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
;; WARNING: recursion requested but not available

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
;; QUESTION SECTION:
;srv.home.arpa. IN A

;; ANSWER SECTION:
srv.home.arpa. 1200 IN A 10.4.0.3

;; Query time: 1 msec
;; SERVER: 127.0.0.1#53(127.0.0.1) (UDP)
;; WHEN: Tue Jul 29 18:58:29 CST 2025
;; MSG SIZE rcvd: 58

$ dig srv.home.arpa

; <<>> DiG 9.18.30-0ubuntu0.24.04.2-Ubuntu <<>> srv.home.arpa
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 36825
;; flags: qr rd; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
;; WARNING: recursion requested but not available

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
;; QUESTION SECTION:
;srv.home.arpa. IN A

;; ANSWER SECTION:
srv.home.arpa. 1199 IN A 10.4.0.3

;; Query time: 0 msec
;; SERVER: 127.0.0.1#53(127.0.0.1) (UDP)
;; WHEN: Tue Jul 29 18:58:30 CST 2025
;; MSG SIZE rcvd: 58

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions