diff --git a/templates/cisco_asa_show_inventory.template b/templates/cisco_asa_show_inventory.template new file mode 100644 index 0000000000..a55c705d91 --- /dev/null +++ b/templates/cisco_asa_show_inventory.template @@ -0,0 +1,12 @@ +Value NAME (\S+) +Value DESCR (.*) +Value PID (\S+) +Value VID (\S+) +Value SN (\S+) + +Start + ^Name:\s+"${NAME}"\s*,\s+DESCR:\s+"${DESCR}" + ^PID:\s+${PID}\s*,\s+VID:\s+${VID}\s*,\s+SN:\s+${SN} -> Record + ^\s*$$ + ^.+ -> Error + diff --git a/templates/index b/templates/index index 5a3bb625b8..8d72120030 100644 --- a/templates/index +++ b/templates/index @@ -100,6 +100,7 @@ cisco_asa_show_running-config_ipsec.template, .*, cisco_asa, sh[[ow]] ru[[nning- cisco_asa_show_crypto_ipsec_sa.template, .*, cisco_asa, sh[[ow]] cry[[pto]] ip[[sec]] sa cisco_asa_show_access-list.template, .*, cisco_asa, sh[[ow]] ac[[cess-list]] cisco_asa_show_interface.template, .*, cisco_asa, sh[[ow]] int[[erface]] +cisco_asa_show_inventory.template, .*, cisco_asa, sh[[ow]] inven[[tory]] cisco_asa_show_version.template, .*, cisco_asa, sh[[ow]] ver[[sion]] cisco_asa_show_route.template, .*, cisco_asa, sh[[ow]] ro[[ute]] cisco_asa_show_name.template, .*, cisco_asa, sh[[ow]] nam[[e]] diff --git a/tests/cisco_asa/show_inventory/cisco_asa_show_inventory.parsed b/tests/cisco_asa/show_inventory/cisco_asa_show_inventory.parsed new file mode 100644 index 0000000000..6ce307bb9f --- /dev/null +++ b/tests/cisco_asa/show_inventory/cisco_asa_show_inventory.parsed @@ -0,0 +1,7 @@ +--- +parsed_sample: +- name: "Chassis" + descr: "ASA 5515-X with SW, 6 GE Data, 1 GE Mgmt, AC" + pid: "ASA5515" + sn: "FTX1930101U" + vid: "V03" diff --git a/tests/cisco_asa/show_inventory/cisco_asa_show_inventory.raw b/tests/cisco_asa/show_inventory/cisco_asa_show_inventory.raw new file mode 100644 index 0000000000..4d18e66067 --- /dev/null +++ b/tests/cisco_asa/show_inventory/cisco_asa_show_inventory.raw @@ -0,0 +1,2 @@ +Name: "Chassis", DESCR: "ASA 5515-X with SW, 6 GE Data, 1 GE Mgmt, AC" +PID: ASA5515 , VID: V03 , SN: FTX1930101U