From 7217b2f9eae89f22aef35717417f261d8a681447 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sat, 30 Jun 2018 22:16:23 +0200 Subject: T714: SNMP: make user auth type mandatory ... if seclevel for group is auth or priv where the user belongs to --- src/conf_mode/snmp.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/conf_mode') diff --git a/src/conf_mode/snmp.py b/src/conf_mode/snmp.py index cbec20731..1590e5de4 100755 --- a/src/conf_mode/snmp.py +++ b/src/conf_mode/snmp.py @@ -651,6 +651,9 @@ def verify(snmp): if user['authPassword'] == '' and user['authMasterKey'] == '': raise ConfigError('Must specify encrypted-key or plaintext-key for user auth') + if user['authProtocol'] == '': + raise ConfigError('Must specify auth type') + # seclevel 'priv' is more restrictive if seclevel is 'priv': if user['privPassword'] and user['privMasterKey']: -- cgit v1.2.3