Request DNSSEC validation and expose the authenticated-data flag
Build a paste-ready command, then review its compatibility and effects before running it.
dig +dnssec <domain> A | awk '/flags:/{print} /ANSWER SECTION:/{show=1;next} show && NF==0{exit} show{print}'Complete required fields to copy the generated command.
Compatibility
Linux + macOSVerified for Linux, macOS using bash, zsh syntax.
Operational knowledgereview due 2027-01-19
Requirementsdigdig must be installed and available on PATH.Network accessThe target must be reachable from the current environment.
Version supportdig Current supported releasesVerified for linux, macos using bash, zsh syntax; consult compatibility notes for platform-specific differences.
Expected signals;; flags: qr rd ra ad; QUERY: 1, ANSWER: 2Representative successful output; values vary with the selected target and system state.
Known errorsdig: command not founddig is missing or is not available on PATH.
Verifydig +dnssec {{domain}} A | awk '/flags:/{print} /ANSWER SECTION:/{show=1;next} show && NF==0{exit} show{print}'The output matches the expected target and exits without an error.Rollback noteNot required: this command is read-only and does not change system state.
Command breakdown
01digCommandRuns the dig stage of this one-liner.
02+dnssecOptionConfigures dig with the +dnssec option.
03<domain>ParameterA value supplied in the Fill parameters section.
05|PipelinePasses the output on the left to the command on the right.
06awkCommandRuns the awk stage of this one-liner.
07'/flags:/{print} /ANSWER SECTION:/{show=1;next} show && NF==0{exit} show{print}'ArgumentPasses '/flags:/{print} /ANSWER SECTION:/{show=1;next} show && NF==0{exit} show{print}' to awk.
This advanced community-curated one-liner combines several stages. Review every option and placeholder before running it.
Example input
dig +dnssec cloudflare.com A | awk '/flags:/{print} /ANSWER SECTION:/{show=1;next} show && NF==0{exit} show{print}'
Example output
;; flags: qr rd ra ad; QUERY: 1, ANSWER: 2
cloudflare.com. 300 IN A 104.16.132.229
cloudflare.com. 300 IN RRSIG A 13 2 300 …
Illustrative output — exact values vary by system and data.
Official sources