From 4f6c87389b313b368d9e833feef55fe6daf7aac9 Mon Sep 17 00:00:00 2001 From: Kelly Brazil Date: Thu, 31 Oct 2019 07:27:31 -0700 Subject: [PATCH] add dig test files --- tests/fixtures/centos-7.7/dig-aaaa.out | 20 ++++++++++++ tests/fixtures/centos-7.7/dig-x.out | 20 ++++++++++++ tests/fixtures/centos-7.7/dig.out | 38 ++++++++++++++++++++++ tests/fixtures/create_fixtures.sh | 6 +++- tests/fixtures/ubuntu-18.04/dig-aaaa.out | 20 ++++++++++++ tests/fixtures/ubuntu-18.04/dig-x.out | 20 ++++++++++++ tests/fixtures/ubuntu-18.04/dig.out | 41 ++++++++++++++++++++++++ 7 files changed, 164 insertions(+), 1 deletion(-) create mode 100644 tests/fixtures/centos-7.7/dig-aaaa.out create mode 100644 tests/fixtures/centos-7.7/dig-x.out create mode 100644 tests/fixtures/centos-7.7/dig.out create mode 100644 tests/fixtures/ubuntu-18.04/dig-aaaa.out create mode 100644 tests/fixtures/ubuntu-18.04/dig-x.out create mode 100644 tests/fixtures/ubuntu-18.04/dig.out diff --git a/tests/fixtures/centos-7.7/dig-aaaa.out b/tests/fixtures/centos-7.7/dig-aaaa.out new file mode 100644 index 00000000..89c5b646 --- /dev/null +++ b/tests/fixtures/centos-7.7/dig-aaaa.out @@ -0,0 +1,20 @@ + +; <<>> DiG 9.11.4-P2-RedHat-9.11.4-9.P2.el7 <<>> www.google.com AAAA +;; global options: +cmd +;; Got answer: +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 25779 +;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1 + +;; OPT PSEUDOSECTION: +; EDNS: version: 0, flags:; MBZ: 0x0005, udp: 4096 +;; QUESTION SECTION: +;www.google.com. IN AAAA + +;; ANSWER SECTION: +www.google.com. 5 IN AAAA 2607:f8b0:4000:808::2004 + +;; Query time: 28 msec +;; SERVER: 192.168.71.2#53(192.168.71.2) +;; WHEN: Wed Oct 30 05:12:53 PDT 2019 +;; MSG SIZE rcvd: 71 + diff --git a/tests/fixtures/centos-7.7/dig-x.out b/tests/fixtures/centos-7.7/dig-x.out new file mode 100644 index 00000000..6f8a2a72 --- /dev/null +++ b/tests/fixtures/centos-7.7/dig-x.out @@ -0,0 +1,20 @@ + +; <<>> DiG 9.11.4-P2-RedHat-9.11.4-9.P2.el7 <<>> -x 1.1.1.1 +;; global options: +cmd +;; Got answer: +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 36298 +;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1 + +;; OPT PSEUDOSECTION: +; EDNS: version: 0, flags:; MBZ: 0x0005, udp: 4096 +;; QUESTION SECTION: +;1.1.1.1.in-addr.arpa. IN PTR + +;; ANSWER SECTION: +1.1.1.1.in-addr.arpa. 5 IN PTR one.one.one.one. + +;; Query time: 32 msec +;; SERVER: 192.168.71.2#53(192.168.71.2) +;; WHEN: Wed Oct 30 05:13:36 PDT 2019 +;; MSG SIZE rcvd: 78 + diff --git a/tests/fixtures/centos-7.7/dig.out b/tests/fixtures/centos-7.7/dig.out new file mode 100644 index 00000000..fff0fd11 --- /dev/null +++ b/tests/fixtures/centos-7.7/dig.out @@ -0,0 +1,38 @@ + +; <<>> DiG 9.11.4-P2-RedHat-9.11.4-9.P2.el7 <<>> www.cnn.com www.google.com +;; global options: +cmd +;; Got answer: +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 44295 +;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 1 + +;; OPT PSEUDOSECTION: +; EDNS: version: 0, flags:; MBZ: 0x0005, udp: 4096 +;; QUESTION SECTION: +;www.cnn.com. IN A + +;; ANSWER SECTION: +www.cnn.com. 5 IN CNAME turner-tls.map.fastly.net. +turner-tls.map.fastly.net. 5 IN A 151.101.189.67 + +;; Query time: 25 msec +;; SERVER: 192.168.71.2#53(192.168.71.2) +;; WHEN: Wed Oct 30 05:13:22 PDT 2019 +;; MSG SIZE rcvd: 95 + +;; Got answer: +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 34074 +;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1 + +;; OPT PSEUDOSECTION: +; EDNS: version: 0, flags:; MBZ: 0x0005, udp: 4096 +;; QUESTION SECTION: +;www.google.com. IN A + +;; ANSWER SECTION: +www.google.com. 5 IN A 216.58.194.100 + +;; Query time: 25 msec +;; SERVER: 192.168.71.2#53(192.168.71.2) +;; WHEN: Wed Oct 30 05:13:22 PDT 2019 +;; MSG SIZE rcvd: 59 + diff --git a/tests/fixtures/create_fixtures.sh b/tests/fixtures/create_fixtures.sh index 843fc9e9..05231031 100644 --- a/tests/fixtures/create_fixtures.sh +++ b/tests/fixtures/create_fixtures.sh @@ -5,13 +5,15 @@ arp -v > arp-v.out arp -a > arp-a.out df > df.out df -h > df-h.out +dig www.google.com AAAA > dig-aaaa.out +dig www.cnn.com www.google.com > dig.out +dig -x 1.1.1.1 > dig-x.out env > env.out free > free.out free -h > free-h.out history > history.out ifconfig > ifconfig.out - sudo iptables -A INPUT -i lo -j ACCEPT sudo iptables -A OUTPUT -o lo -j ACCEPT sudo iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT @@ -28,6 +30,7 @@ sudo iptables -nvL -t filter > iptables-filter-nv.out sleep 11 & sleep 12 & sleep 13 & sleep 14 & jobs > jobs.out + ls / > ls.out ls -al / > ls-al.out ls -alh / > ls-alh.out @@ -42,6 +45,7 @@ git clone https://github.com/kellyjonbrazil/jc.git /tmp/jc & sleep 1; netstat netstat -p > netstat-p.out netstat -l > netstat-l.out sudo netstat -lnp > netstat-sudo-lnp.out + ps -ef > ps-ef.out ps axu > ps-axu.out route > route.out diff --git a/tests/fixtures/ubuntu-18.04/dig-aaaa.out b/tests/fixtures/ubuntu-18.04/dig-aaaa.out new file mode 100644 index 00000000..cfbcf203 --- /dev/null +++ b/tests/fixtures/ubuntu-18.04/dig-aaaa.out @@ -0,0 +1,20 @@ + +; <<>> DiG 9.11.3-1ubuntu1.8-Ubuntu <<>> www.google.com AAAA +;; global options: +cmd +;; Got answer: +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 45806 +;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1 + +;; OPT PSEUDOSECTION: +; EDNS: version: 0, flags:; udp: 65494 +;; QUESTION SECTION: +;www.google.com. IN AAAA + +;; ANSWER SECTION: +www.google.com. 5 IN AAAA 2607:f8b0:4000:812::2004 + +;; Query time: 39 msec +;; SERVER: 127.0.0.53#53(127.0.0.53) +;; WHEN: Thu Oct 31 14:21:04 UTC 2019 +;; MSG SIZE rcvd: 71 + diff --git a/tests/fixtures/ubuntu-18.04/dig-x.out b/tests/fixtures/ubuntu-18.04/dig-x.out new file mode 100644 index 00000000..54896e5a --- /dev/null +++ b/tests/fixtures/ubuntu-18.04/dig-x.out @@ -0,0 +1,20 @@ + +; <<>> DiG 9.11.3-1ubuntu1.8-Ubuntu <<>> -x 1.1.1.1 +;; global options: +cmd +;; Got answer: +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 28514 +;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1 + +;; OPT PSEUDOSECTION: +; EDNS: version: 0, flags:; udp: 65494 +;; QUESTION SECTION: +;1.1.1.1.in-addr.arpa. IN PTR + +;; ANSWER SECTION: +1.1.1.1.in-addr.arpa. 5 IN PTR one.one.one.one. + +;; Query time: 37 msec +;; SERVER: 127.0.0.53#53(127.0.0.53) +;; WHEN: Thu Oct 31 14:21:05 UTC 2019 +;; MSG SIZE rcvd: 78 + diff --git a/tests/fixtures/ubuntu-18.04/dig.out b/tests/fixtures/ubuntu-18.04/dig.out new file mode 100644 index 00000000..b4bdc571 --- /dev/null +++ b/tests/fixtures/ubuntu-18.04/dig.out @@ -0,0 +1,41 @@ + +; <<>> DiG 9.11.3-1ubuntu1.8-Ubuntu <<>> www.cnn.com www.google.com +;; global options: +cmd +;; Got answer: +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 52284 +;; flags: qr rd ra; QUERY: 1, ANSWER: 5, AUTHORITY: 0, ADDITIONAL: 1 + +;; OPT PSEUDOSECTION: +; EDNS: version: 0, flags:; udp: 65494 +;; QUESTION SECTION: +;www.cnn.com. IN A + +;; ANSWER SECTION: +www.cnn.com. 5 IN CNAME turner-tls.map.fastly.net. +turner-tls.map.fastly.net. 4 IN A 151.101.65.67 +turner-tls.map.fastly.net. 4 IN A 151.101.1.67 +turner-tls.map.fastly.net. 4 IN A 151.101.193.67 +turner-tls.map.fastly.net. 4 IN A 151.101.129.67 + +;; Query time: 31 msec +;; SERVER: 127.0.0.53#53(127.0.0.53) +;; WHEN: Thu Oct 31 14:21:04 UTC 2019 +;; MSG SIZE rcvd: 143 + +;; Got answer: +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 47686 +;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1 + +;; OPT PSEUDOSECTION: +; EDNS: version: 0, flags:; udp: 65494 +;; QUESTION SECTION: +;www.google.com. IN A + +;; ANSWER SECTION: +www.google.com. 5 IN A 172.217.1.228 + +;; Query time: 32 msec +;; SERVER: 127.0.0.53#53(127.0.0.53) +;; WHEN: Thu Oct 31 14:21:04 UTC 2019 +;; MSG SIZE rcvd: 59 +