diff --git a/templates/index b/templates/index index ad0bb8e6e1..8dc7518b2c 100644 --- a/templates/index +++ b/templates/index @@ -310,6 +310,7 @@ paloalto_panos_show_counter_global.template, .*, paloalto_panos, sh[[ow]] coun[[ paloalto_panos_show_system_info.template, .*, paloalto_panos, sh[[ow]] sys[[tem]] in[[fo]] paloalto_panos_show_jobs_all.template, .*, paloalto_panos, sh[[ow]] jo[[bs]] all paloalto_panos_show_arp_all.template, .*, paloalto_panos, sh[[ow]] ar[[p]] all +paloalto_panos_show_mac_all.template, .*, paloalto_panos, sh[[ow]] mac all ubiquiti_edgeswitch_show_vlan.template, .*, ubiquiti_edgeswitch, sh[[ow]] vl[[an]] ubiquiti_edgeswitch_show_arp.template, .*, ubiquiti_edgeswitch, sh[[ow]] ar[[p]] diff --git a/templates/paloalto_panos_show_mac_all.template b/templates/paloalto_panos_show_mac_all.template new file mode 100644 index 0000000000..2750d2120f --- /dev/null +++ b/templates/paloalto_panos_show_mac_all.template @@ -0,0 +1,13 @@ +Value VLAN (\S+) +Value MAC ([0-9a-fA-F:]+) +Value INTERFACE (\S+) +Value STATUS (\S+) +Value TTL (\d+) + +Start + ^\s*--- -> Start_record + +Start_record + ^${VLAN}\s+${MAC}\s+${INTERFACE}\s+${STATUS}\s+${TTL} -> Record + ^\s*$$ + ^. -> Error diff --git a/tests/paloalto_panos/show_mac_all/paloalto_panos_show_mac_all.parsed b/tests/paloalto_panos/show_mac_all/paloalto_panos_show_mac_all.parsed new file mode 100644 index 0000000000..e95b162037 --- /dev/null +++ b/tests/paloalto_panos/show_mac_all/paloalto_panos_show_mac_all.parsed @@ -0,0 +1,18 @@ +--- +parsed_sample: + +- vlan: Test + mac: '00:50:00:00:07:00' + interface: ethernet1/2.110 + status: c + ttl: '1778' +- vlan: Test + mac: '00:50:00:00:08:00' + interface: ethernet1/2.111 + status: c + ttl: '1796' +- vlan: Test + mac: '50:00:00:02:00:01' + interface: ethernet1/2.110 + status: c + ttl: '704' diff --git a/tests/paloalto_panos/show_mac_all/paloalto_panos_show_mac_all.raw b/tests/paloalto_panos/show_mac_all/paloalto_panos_show_mac_all.raw new file mode 100644 index 0000000000..f5fcfd78cc --- /dev/null +++ b/tests/paloalto_panos/show_mac_all/paloalto_panos_show_mac_all.raw @@ -0,0 +1,12 @@ + +maximum of entries supported : 1500 +default timeout : 1800 seconds +total MAC entries in table : 3 +total MAC entries shown : 3 +status: s - static, c - complete, i - incomplete + +vlan hw address interface status ttl +-------------------------------------------------------------------------------- +Test 00:50:00:00:07:00 ethernet1/2.110 c 1778 +Test 00:50:00:00:08:00 ethernet1/2.111 c 1796 +Test 50:00:00:02:00:01 ethernet1/2.110 c 704