EOS management access
Rules for how admins reach the switch: no Telnet, idle SSH sessions closed, no weak SSH algorithms, and a warning before login. They come from the eos-management-access policy template.
Every example on this page was checked with rConfig Pro's policy engine on Each of the 9 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. A card marked changed has one line edited to show a failure.
All the rules come from eos-management-access.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 |
|---|---|---|
| Telnet is not enabled | must_not_match_regex |
8.0.2 |
| SSH idle timeout | evaluate_block |
8.3.0 |
| No weak SSH ciphers or MACs | must_not_match_regex |
8.0.2 |
| Login banner | must_match_regex |
8.0.0 |
Telnet is not enabled
Telnet sends logins in clear text. On EOS it is on only when management telnet has a no shutdown line under it. This rule fails on that line, so it passes on a switch that prints no management telnet block.
// Telnet is not enabled (fails on no shutdown under management telnet)#[must_not_match_regex]/^management telnet\n(?:[ \t]+.*\n)*?[ \t]+no shutdown$/mmanagement ssh idle-timeout 10 authentication protocol password ! vrf MGMT no shutdown!!management api http-commands protocol https no shutdownWhy: There is no management telnet block, so Telnet is at its default: off.
vrf instance MGMT!management telnet no shutdown!Why: management telnet has no shutdown, so Telnet is on.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| NIST SP 800-53 | AC-17 |
| HIPAA (45 CFR) | 164.312(a)(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.
SSH idle timeout
An SSH session left open is an open door. EOS has no idle timeout by default and does not print the default, so this rule needs an explicit idle-timeout of 1 to 10 minutes under management ssh. A switch with no management ssh block fails.
// The SSH idle timeout is 1 to 10 minutes (idle-timeout under management ssh)#[evaluate_block]scope: ^management ssh$all: - regex: '/^\s+idle-timeout ([1-9]|10)$/m'management ssh idle-timeout 10 authentication protocol password ! vrf MGMT no shutdown!Why: The idle timeout is 10 minutes.
management ssh idle-timeout 15 cipher aes256-cbc aes256-ctr authentication protocol password ! vrf MGMT no shutdown!Why: The idle timeout is 15 minutes, more than 10.
management ssh authentication protocol password ! vrf MGMT no shutdown idle-timeout 10!Why: The timeout is 10, but it comes after the nested ! line. rConfig ends the management ssh block at that line, so the rule never sees idle-timeout.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config | pass | PASS |
| Failing config 1 | fail | FAIL |
| Failing config 2 | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| NIST SP 800-53 | AC-3 |
| ISO/IEC 27001:2022 Annex A | A.8.5 |
Tested with: sample excerpts from EOS 4.32.2F (synthetic). Minimum rConfig 8.3.0 (evaluate_block). Editions: Pro, Vector, Enterprise.
No weak SSH ciphers or MACs
CBC mode, 3DES, arcfour and blowfish ciphers, and MD5 or SHA-1 MACs, are weak. This rule fails on any indented cipher or mac line that names one of them. EOS does not print its default list, so the rule only sees algorithms you set explicitly.
// No SSH cipher or MAC line selects a CBC, 3DES, arcfour, blowfish, MD5 or SHA-1 algorithm (cipher, mac)#[must_not_match_regex]/^[ \t]+(cipher .*(cbc|3des|arcfour|blowfish)|mac .*\bhmac-(md5|sha1)\b)/mmanagement ssh idle-timeout 10 authentication protocol password ! vrf MGMT no shutdown!Why: No cipher or mac line is set, so EOS uses its default list.
management ssh idle-timeout 15 cipher aes256-cbc aes256-ctr authentication protocol password ! vrf MGMT no shutdown!Why: aes256-cbc is a CBC cipher. The CTR cipher next to it does not make the line pass.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| ISO/IEC 27001:2022 Annex A | 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.
Login banner
A login banner warns users before they sign in. EOS prints banner login on its own line, then the text, then EOF. This rule matches the banner login line, so any text passes.
// A login banner is configured (banner login)#[must_match_regex]/^banner login$/m!banner loginAuthorised access only. This device belongs to Example Ltd.All activity is logged and monitored. Disconnect now if you are not an authorised user.EOF!management ssh idle-timeout 10Why: A login banner is set.
router bgp 64500 address-family ipv4 no neighbor EVPN-OVERLAY-PEERS activate neighbor IPv4-UNDERLAY-PEERS activate!!management ssh idle-timeout 15Why: There is no banner login line.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| ISO/IEC 27001:2022 Annex A | A.8.5 |
Tested with: sample excerpts from EOS 4.32.2F (synthetic). Minimum rConfig 8.0.0 (must_match_regex). Editions: Pro, Vector, Enterprise.
Related reference
- Arista EOS policy templates: every rule in
eos-management-access.policy, its references and known limitations. - Policy Definitions: the definition file format and every method.
- Policy Assignments: run a definition against your devices.
- Policy Compliance Results: read the pass and fail results.