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

New template cisco_ios_show_snmp_user.template #429

Merged
merged 8 commits into from
Jul 26, 2019
Merged
Changes from 1 commit
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
17 changes: 17 additions & 0 deletions templates/cisco_ios_show_snmp_user.template
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
Value Required USER_NAME (\w+)
Value ENGINE_ID (\w+)
Value STORAGE_TYPE (\w+)
Value STORAGE_TYPE_ACTIVE (\w+)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should change the STORAGE_TYPE_ACTIVE to ACCESS_LIST to capture d+ as that appears from the Cisco docs as to what it is referring to:

https://www.cisco.com/c/en/us/td/docs/ios-xml/ios/snmp/command/nm-snmp-cr-book/nm-snmp-cr-s1.html#wp8434359780

And then change L12 to:
^storage-type:\s${STORAGE_TYPE}\s+active$$

And add the following line right above:
^storage-type:\s${STORAGE_TYPE}\s+active\s+access-list:\s+${ACCESS_LIST}$$

Value AUTHENTICATION_PROTOCOL (\w+)
Value PRIVACY_PROTOCOL (\w+)
Value GROUP_NAME (\w+)

Start
^User\s+name:\s+${USER_NAME}$$
^Engine\s+ID:\s+${ENGINE_ID}$$
^storage-type:\s${STORAGE_TYPE}\s+${STORAGE_TYPE_ACTIVE}$$
^Authentication\s+Protocol:\s+${AUTHENTICATION_PROTOCOL}$$
^Privacy\s+Protocol:\s+${PRIVACY_PROTOCOL}$$
^Group-name:\s+${GROUP_NAME}$$ -> Record
^\s*$$
^. -> Error