Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linux arp a #814

Merged
merged 7 commits into from
Oct 22, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions templates/index
Original file line number Diff line number Diff line change
Expand Up @@ -402,6 +402,8 @@ juniper_junos_show_version.textfsm, .*, juniper_junos, sh[[ow]] ver[[sion]]

juniper_screenos_get_route.textfsm, .*, juniper_screenos, get route

linux_arp_a.textfsm, .*, linux, arp -a

paloalto_panos_show_running_security-policy.textfsm, .*, paloalto_panos, sh[[ow]] runn[[ing]] security[[-policy]]
paloalto_panos_show_high-availability_all.textfsm, .*, paloalto_panos, sh[[ow]] high[[-availability]] all
paloalto_panos_show_interface_management.textfsm, .*, paloalto_panos, sh[[ow]] int[[erface]] man[[agement]]
Expand Down
8 changes: 8 additions & 0 deletions templates/linux_arp_a.textfsm
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
Value REV_DNS (\S+)
Value IP_ADDRESS (\S+)
Value MAC_ADDRESS (\S+)
Value HW_TYPE (\S+)
Value INTERFACE (\S+)

Start
^${REV_DNS}\s+\(${IP_ADDRESS}\)\s+at\s+${MAC_ADDRESS}\s+\[${HW_TYPE}\]\s+on\s+${INTERFACE}$$ -> Record
jmcgill298 marked this conversation as resolved.
Show resolved Hide resolved
9 changes: 9 additions & 0 deletions tests/linux/arp_a/linux_arp_a.raw
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
? (192.168.13.197) at 00:04:4b:cc:9c:ba [ether] on eth1.100
? (192.168.10.100) at <incomplete> on eth1.10
? (192.168.13.252) at 5c:e2:8c:fc:a4:74 [ether] on eth1.100
esxi (192.168.13.5) at 00:e0:67:05:9d:5a [ether] on eth1.100
? (192.168.13.253) at dc:f7:19:cd:d6:c4 [ether] on eth1.100
? (192.168.123.199) at 00:0f:c9:0e:c8:ec [ether] on eth0.21
? (192.168.10.52) at <incomplete> on eth1.10
? (192.168.10.7) at 00:0c:29:02:3b:93 [ether] on eth1.10
? (192.168.10.249) at 00:0c:29:bb:5f:a2 [ether] on eth1.10
37 changes: 37 additions & 0 deletions tests/linux/arp_a/linux_arp_a.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
parsed_sample:
- hw_type: "ether"
interface: "eth1.100"
ip_address: "192.168.13.197"
mac_address: "00:04:4b:cc:9c:ba"
rev_dns: "?"
- hw_type: "ether"
interface: "eth1.100"
ip_address: "192.168.13.252"
mac_address: "5c:e2:8c:fc:a4:74"
rev_dns: "?"
- hw_type: "ether"
interface: "eth1.100"
ip_address: "192.168.13.5"
mac_address: "00:e0:67:05:9d:5a"
rev_dns: "esxi"
- hw_type: "ether"
interface: "eth1.100"
ip_address: "192.168.13.253"
mac_address: "dc:f7:19:cd:d6:c4"
rev_dns: "?"
- hw_type: "ether"
interface: "eth0.21"
ip_address: "192.168.123.199"
mac_address: "00:0f:c9:0e:c8:ec"
rev_dns: "?"
- hw_type: "ether"
interface: "eth1.10"
ip_address: "192.168.10.7"
mac_address: "00:0c:29:02:3b:93"
rev_dns: "?"
- hw_type: "ether"
interface: "eth1.10"
ip_address: "192.168.10.249"
mac_address: "00:0c:29:bb:5f:a2"
rev_dns: "?"