diff --git a/ntc_templates/templates/cisco_asa_show_running-config_access-group.textfsm b/ntc_templates/templates/cisco_asa_show_running-config_access-group.textfsm new file mode 100644 index 0000000000..01ed69b48c --- /dev/null +++ b/ntc_templates/templates/cisco_asa_show_running-config_access-group.textfsm @@ -0,0 +1,6 @@ +Value ACCESS_LIST (\S+) +Value INTERFACE (\S+) + +Start + ^access-group\s+${ACCESS_LIST}\s+in\s+interface\s+${INTERFACE}\s*$$ -> Record + ^. -> Error "Did not match any entries" diff --git a/ntc_templates/templates/index b/ntc_templates/templates/index index ccf6a34013..88599cbfd8 100644 --- a/ntc_templates/templates/index +++ b/ntc_templates/templates/index @@ -204,6 +204,7 @@ cisco_asa_show_module.textfsm:cisco_asa_show_module_details.textfsm:cisco_asa_sh cisco_asa_show_running-config_all_crypto_map.textfsm, .*, cisco_asa, sh[[ow]] ru[[nning-config]] all cr[[ypto]] m[[ap]] cisco_asa_show_running-config_object_network.textfsm, .*, cisco_asa, sh[[ow]] ru[[nning-config]] o[[bject]] n[[etwork]] cisco_asa_show_asp_table_vpn-context_detail.textfsm, .*, cisco_asa, sh[[ow]] asp t[[able]] vpn-co[[ntext]] d[[etail]] +cisco_asa_show_running-config_access-group.textfsm, .*, cisco_asa, sh[[ow]] ru[[nning-config]] access-gr[[oup]] cisco_asa_show_running-config_crypto_ikev1.textfsm, .*, cisco_asa, sh[[ow]] ru[[nning-config]] cr[[ypto]] ikev1 cisco_asa_show_running-config_tunnel-group.textfsm, .*, cisco_asa, sh[[ow]] ru[[nning-config]] tu[[nnel-group]] cisco_asa_show_running-config_crypto_map.textfsm, .*, cisco_asa, sh[[ow]] ru[[nning-config]] cr[[ypto]] m[[ap]] diff --git a/tests/cisco_asa/show_running-config_access-group/show_running-config_access-group.raw b/tests/cisco_asa/show_running-config_access-group/show_running-config_access-group.raw new file mode 100644 index 0000000000..41f102ea55 --- /dev/null +++ b/tests/cisco_asa/show_running-config_access-group/show_running-config_access-group.raw @@ -0,0 +1,7 @@ +access-group INSIDE_acl in interface inside +access-group dmz1_acl in interface dmz1 +access-group dmz2_acl in interface dmz2 +access-group dmz3_acl in interface dmz3 +access-group dmz4 in interface dmz4 +access-group dmz5 in interface dmz5 +access-group OUTSIDE_acl in interface outside diff --git a/tests/cisco_asa/show_running-config_access-group/show_running-config_access-group.yml b/tests/cisco_asa/show_running-config_access-group/show_running-config_access-group.yml new file mode 100644 index 0000000000..faf52fd8b8 --- /dev/null +++ b/tests/cisco_asa/show_running-config_access-group/show_running-config_access-group.yml @@ -0,0 +1,16 @@ +--- +parsed_sample: + - access_list: "INSIDE_acl" + interface: "inside" + - access_list: "dmz1_acl" + interface: "dmz1" + - access_list: "dmz2_acl" + interface: "dmz2" + - access_list: "dmz3_acl" + interface: "dmz3" + - access_list: "dmz4" + interface: "dmz4" + - access_list: "dmz5" + interface: "dmz5" + - access_list: "OUTSIDE_acl" + interface: "outside"