Skip to content
Guides & References

EOS SNMP

Worked examples for the Arista EOS SNMP template: no SNMPv1 or v2c communities, an SNMPv3 authPriv group, and no SNMPv3 user with MD5 or DES.

Policy LibraryUpdated
Platform
arista-eos
Minimum version
rConfig 8.0.2
Editions
Pro, Vector, Enterprise
On this page

EOS SNMP

Rules for SNMP: no community strings, SNMPv3 with authentication and encryption, and no weak SNMPv3 algorithms. EOS prints SNMPv3 users in show running-config, so the user rule can see them. They come from the eos-snmp policy template.

Every example on this page was checked with rConfig Pro's policy engine on

Each of the 6 configs below was run through rConfig Pro’s evaluator with the rule above it, and gave the result shown. The configs are sanitised excerpts of the sample configs that come with the template.

All the rules come from eos-snmp.policy in the policy templates (v1.5.0). Import the whole file with Import Templates (see importing a policy template), or copy one rule into your own definition. The Arista EOS templates page lists the file’s known limitations. Run the rules against show running-config.

Rule Method Since
No SNMPv1 or v2c communities must_not_match_regex 8.0.2
SNMPv3 group with authPriv must_match_regex 8.0.0
No MD5 or DES SNMPv3 users must_not_match_regex 8.0.2

No SNMPv1 or v2c communities

SNMPv1 and v2c send the community string in clear text, and it works like a password. This rule fails on any snmp-server community line.

Definition
// No SNMPv1 or SNMPv2c community is configured (fails on snmp-server community)
#[must_not_match_regex]
/^snmp-server community /m
passPassing config: Hardened DCS-7280CR3 sample (EOS 4.32.2F, synthetic)
snmp-server contact NetOps <netops@example.com>
snmp-server location Dublin DC1, Hall A
snmp-server group NMS v3 priv
snmp-server user nms NMS v3 localized f5717f2899ab0100 auth sha 7d1e4b0c2f9a8e6d5c4b3a291807f6e5d4c3b2a1 priv aes 0a1b2c3d4e5f60718293a4b5c6d7e8f9
snmp-server host 192.0.2.60 vrf MGMT version 3 priv nms
snmp-server vrf MGMT

Why: Only SNMPv3 is set up.

failFailing config: Unhardened DCS-7280CR3 sample (EOS 4.32.2F, synthetic)
snmp-server contact NetOps <netops@example.com>
snmp-server community dc1-ro ro SNMP-MGMT
snmp-server group NMS v3 auth
snmp-server host 192.0.2.60 vrf MGMT version 2c dc1-ro

Why: There is a v2c community.

Expected result in rConfig, with this rule as the only rule in a definition:

ConfigRule resultOverall result
Passing configpassPASS
Failing configfailFAIL

Framework mapping. The rule provides evidence towards these controls. It does not certify anything.

Framework Reference
NIST SP 800-53 SC-12
HIPAA (45 CFR) 164.312(e)(1)
ISO/IEC 27001:2022 Annex A A.8.5

Tested with: sample excerpts from EOS 4.32.2F (synthetic). Minimum rConfig 8.0.2 (must_not_match_regex). Editions: Pro, Vector, Enterprise.


SNMPv3 group with authPriv

priv is the SNMPv3 level with both authentication and encryption. This rule needs at least one snmp-server group at v3 priv.

Definition
// An SNMPv3 group uses authPriv (snmp-server group ... v3 priv)
#[must_match_regex]
/^snmp-server group \S+ v3 priv\b/m
passPassing config: Hardened DCS-7280CR3 sample (EOS 4.32.2F, synthetic)
snmp-server group NMS v3 priv
snmp-server user nms NMS v3 localized f5717f2899ab0100 auth sha 7d1e4b0c2f9a8e6d5c4b3a291807f6e5d4c3b2a1 priv aes 0a1b2c3d4e5f60718293a4b5c6d7e8f9

Why: The NMS group uses v3 priv.

failFailing config: Unhardened DCS-7280CR3 sample (EOS 4.32.2F, synthetic)
snmp-server community dc1-ro ro SNMP-MGMT
snmp-server group NMS v3 auth
snmp-server user nms NMS v3 localized f5717f2899ab0100 auth md5 3c4b5a6978e1f20d1c2b3a4958677685 priv des 9e8d7c6b5a4f30211f2e3d4c5b6a7988

Why: The group uses v3 auth, which has no encryption.

Expected result in rConfig, with this rule as the only rule in a definition:

ConfigRule resultOverall result
Passing configpassPASS
Failing configfailFAIL

Framework mapping. The rule provides evidence towards these controls. It does not certify anything.

Framework Reference
NIST SP 800-53 SC-12
HIPAA (45 CFR) 164.312(e)(1)
ISO/IEC 27001:2022 Annex A A.8.5, A.8.24

Tested with: sample excerpts from EOS 4.32.2F (synthetic). Minimum rConfig 8.0.0 (must_match_regex). Editions: Pro, Vector, Enterprise.


No MD5 or DES SNMPv3 users

MD5 and DES are weak. This rule fails on an snmp-server user line with auth md5, priv des or priv 3des. Use auth sha (or stronger) and priv aes.

Definition
// No SNMPv3 user uses MD5 authentication or DES privacy (fails on snmp-server user ... auth md5 or priv des)
#[must_not_match_regex]
/^snmp-server user \S+ \S+ .*\b(auth md5|priv (des|3des))\b/m
passPassing config: Hardened DCS-7280CR3 sample (EOS 4.32.2F, synthetic)
snmp-server group NMS v3 priv
snmp-server user nms NMS v3 localized f5717f2899ab0100 auth sha 7d1e4b0c2f9a8e6d5c4b3a291807f6e5d4c3b2a1 priv aes 0a1b2c3d4e5f60718293a4b5c6d7e8f9

Why: The user has SHA authentication and AES privacy.

failFailing config: Unhardened DCS-7280CR3 sample (EOS 4.32.2F, synthetic)
snmp-server group NMS v3 auth
snmp-server user nms NMS v3 localized f5717f2899ab0100 auth md5 3c4b5a6978e1f20d1c2b3a4958677685 priv des 9e8d7c6b5a4f30211f2e3d4c5b6a7988

Why: The user has MD5 authentication and DES privacy.

Expected result in rConfig, with this rule as the only rule in a definition:

ConfigRule resultOverall result
Passing configpassPASS
Failing configfailFAIL

Framework mapping. The rule provides evidence towards these controls. It does not certify anything.

Framework Reference
NIST SP 800-53 SC-12
HIPAA (45 CFR) 164.312(e)(1)
ISO/IEC 27001:2022 Annex A A.8.5, A.8.24

Tested with: sample excerpts from EOS 4.32.2F (synthetic). Minimum rConfig 8.0.2 (must_not_match_regex). Editions: Pro, Vector, Enterprise.


Type to search.