152
SNMPv3 users are valid only on the SNMP engine that creates them. By default, SNMPv3 users are
created on the local SNMP engine. When you create an SNMPv3 user for sending SNMP inform
messages, you must associate it with the remote SNMP engine.
For security purposes, all keys, including keys configured in plain text, are saved in cipher text.
Make sure you remember the username and the plain text of the keys. When you access the device
from an NMS, you must provide this information.
Examples
In VACM mode:
# Add the user
testUser
to the SNMPv3 group
testGroup
, and enable the authentication without
privacy security model for the group. Specify the authentication algorithm SHA-1 and the
authentication key
123456TESTplat&!
in plain text for the user.
<Sysname> system-view
[Sysname] snmp-agent group v3 testGroup authentication
[Sysname] snmp-agent usm-user v3 testUser testGroup simple authentication-mode sha
123456TESTplat&!
# For an NMS to access the MIB objects in the default view
ViewDefault
, make sure the following
configurations on the NMS are the same as the SNMP agent:
•
SNMPv3 username.
•
SNMP protocol version.
•
Authentication algorithm and key.
# Add the user
testUser
to the SNMPv3 group
testGroup
, and enable the authentication and
privacy security model for the group. Specify the authentication algorithm SHA-1, the privacy
algorithm AES, the plaintext authentication key
123456TESTauth&!
, and
the plaintext privacy key
123456TESTencr&!
for the user.
<Sysname> system-view
[Sysname] snmp-agent group v3 testGroup privacy
[Sysname] snmp-agent usm-user v3 testUser testGroup simple authentication-mode sha
123456TESTauth&! privacy-mode aes128 123456TESTencr&!
# For an NMS to access the MIB objects in the default view
ViewDefault
, make sure the following
configurations on the NMS are the same as the SNMP agent:
•
SNMPv3 username.
•
SNMP protocol version.
•
Authentication algorithm.
•
Privacy algorithm.
•
Plaintext authentication and privacy keys.
# Add the user
remoteUser
for the SNMP remote engine at
10.1.1.1 to the SNMPv3 group
testGroup
, enable the authentication and privacy security model for the group, specify the
authentication algorithm SHA-1, the privacy algorithm AES, the plaintext authentication key
123456TESTauth&!
, and
the plaintext privacy key
123456TESTencr&!
for the user.
<Sysname> system-view
[Sysname] snmp-agent remote 10.1.1.1 engineid 123456789A
[Sysname] snmp-agent group v3 testGroup privacy
[Sysname] snmp-agent usm-user v3 remoteUser testGroup remote 10.1.1.1 simple
authentication-mode sha 123456TESTauth&! privacy-mode aes128 123456TESTencr&!
In RBAC mode:
# Create the SNMPv3 user
testUser
with the user role
network-operator
and enable the
authentication without privacy security model for the user. Specify the authentication algorithm
SHA-1 and the authentication key
123456TESTplat&!
in plain text for the user.