Test if a name server supports EDNS

From Brandonhutchinson.com

Revision as of 20:11, 18 August 2008 by Hutch (Talk | contribs)
Jump to: navigation, search

Use the following to test if a name server supports EDNS, specifically EDNS0 in the examples below.

When testing a name server, make sure to send a query that will result in authoritative answer. For example, if ns.example.com is authoritative for example.com, send a query such as example.com soa. Sending a query for something like . ns to the name server will result in a timeout when specifying +edns=0.

dig +edns

  • If your version of dig supports +edns=#, use the following:
$ dig @nameserver +noall +comments +edns=0 query
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 26316
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 9, ADDITIONAL: 10

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096

dig +bufsize

  • If your version of dig does not support +edns=#, you will have to use +bufsize=B.
  • According to dig(1), sending a non-zero bufsize causes an EDNS query to be sent.
$ dig @nameserver +noall +comments +bufsize=1 query
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 61334
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 9, ADDITIONAL: 10

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
Personal tools