forked from networktocode/ntc-templates
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New Template - cisco_ios_show_object-group (networktocode#850)
- Loading branch information
1 parent
12e58e4
commit c93de9c
Showing
4 changed files
with
561 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
Value Required,Filldown TYPE (Service|Network) | ||
Value Required,Filldown NAME (\S+) | ||
Value DESCRIPTION (.+) | ||
Value NESTED_GROUPS (\S+) | ||
Value ANY (any) | ||
Value HOST (\d+\.\d+\.\d+\.\d+) | ||
Value HOST_RANGE_START (\d+\.\d+\.\d+\.\d+) | ||
Value HOST_RANGE_END (\d+\.\d+\.\d+\.\d+) | ||
Value NETWORK (\d+\.\d+\.\d+\.\d+) | ||
Value NETMASK (\d+\.\d+\.\d+\.\d+) | ||
Value PROTOCOL (\S+) | ||
Value PORT_MATCH (eq|neq|range|lt|gt) | ||
Value PORT ((?<!range\s)\S+) | ||
Value PORT_RANGE_START ((?<=range\s)\S+) | ||
Value PORT_RANGE_END (\S+) | ||
Value ICMP_TYPE (echo|echo-reply|administratively-prohibited|unreachable|port-unreachable|redirect|router-advertisement|router-solicitation|packet-too-big|time-exceeded|ttl-exceeded|parameter-problem) | ||
|
||
Start | ||
^(Service|Network) -> Continue.Clearall | ||
^${TYPE}\s+object\s+group\s+${NAME}\s*$$ -> Record | ||
^\s+Description\s+${DESCRIPTION}$$ -> Record | ||
^\s+group-object\s+${NESTED_GROUPS}\s*$$ -> Record | ||
^\s+(host\s+${HOST}|range\s+${HOST_RANGE_START}\s+${HOST_RANGE_END}|${ANY}|${NETWORK}\s+${NETMASK})\s*$$ -> Record | ||
^\s+icmp\s+${ICMP_TYPE}\s*$$ -> Record | ||
^\s+${PROTOCOL}\s+${PORT_MATCH}\s+(${PORT_RANGE_START}\s+${PORT_RANGE_END}|${PORT})\s*$$ -> Record | ||
^\s+${PROTOCOL}\s*$$ -> Record | ||
^\s*$$ | ||
^. -> Error | ||
|
||
EOF | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
tests/cisco_ios/show_object-group/cisco_ios_show_object-group.raw
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
Network object group NNNN | ||
Service object group SSSS | ||
Service object group TEST-SVC-OGR | ||
Description ! Test Service Group ! | ||
icmp echo-reply | ||
tcp eq smtp | ||
udp eq tacacs | ||
udp range tacacs 50 | ||
tcp range 79 www | ||
tcp eq www | ||
tcp eq 81 | ||
udp lt 999 | ||
udp gt 97 | ||
tcp-udp range 12200 12700 | ||
icmp | ||
tcp | ||
udp | ||
tcp-udp range 0 65535 | ||
group-object SSSS | ||
ip | ||
ipinip | ||
99 | ||
Network object group TEST_NET_OGR | ||
Description ###TEST NETWORK OGR### | ||
any | ||
host 1.1.1.1 | ||
range 2.2.2.2 3.3.3.3 | ||
group-object NNNN | ||
1.1.1.0 255.255.255.0 | ||
Network object group XXXX | ||
Network object group YYYY |
Oops, something went wrong.