DNS
DNSの情報収集
dig
バージョン情報
$ dig version.bind CHAOS TXT @10.10.10.48
; <<>> DiG 9.18.1-1-Debian <<>> version.bind CHAOS TXT @10.10.10.48
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 35047
;; flags: qr aa rd ra ad; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;version.bind. CH TXT
;; ANSWER SECTION:
version.bind. 300 CH TXT "dnsmasq-2.76"
;; Query time: 92 msec
;; SERVER: 10.10.10.48#53(10.10.10.48) (UDP)
;; WHEN: Wed Sep 07 00:48:38 JST 2022
;; MSG SIZE rcvd: 66
逆引き
$ dig -x 10.10.10.48 @10.10.10.48
ANY
$ dig ANY @10.10.10.29 bank.htb
; <<>> DiG 9.18.1-1-Debian <<>> ANY @10.10.10.29 bank.htb
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 22166
;; flags: qr aa rd; QUERY: 1, ANSWER: 3, AUTHORITY: 0, ADDITIONAL: 2
;; WARNING: recursion requested but not available
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;bank.htb. IN ANY
;; ANSWER SECTION:
bank.htb. 604800 IN SOA bank.htb. chris.bank.htb. 5 604800 86400 2419200 604800
bank.htb. 604800 IN NS ns.bank.htb.
bank.htb. 604800 IN A 10.10.10.29
;; ADDITIONAL SECTION:
ns.bank.htb. 604800 IN A 10.10.10.29
;; Query time: 92 msec
;; SERVER: 10.10.10.29#53(10.10.10.29) (TCP)
;; WHEN: Wed Sep 07 13:43:15 JST 2022
;; MSG SIZE rcvd: 128