From 10b5196ddfb9a83b17f90f93524ea077275a8557 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sat, 11 Jul 2020 18:03:36 +0200 Subject: snmp: adjust to latest CLI version --- scripts/cli/test_service_snmp.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'scripts') diff --git a/scripts/cli/test_service_snmp.py b/scripts/cli/test_service_snmp.py index d4bbdc0b1..983eadf4c 100755 --- a/scripts/cli/test_service_snmp.py +++ b/scripts/cli/test_service_snmp.py @@ -84,7 +84,7 @@ class TestSNMPService(unittest.TestCase): def test_snmpv3(self): """ Check if SNMPv3 can be configured and service runs""" - self.session.set(base_path + ['v3', 'engineid', '0xaffedeadbeef']) + self.session.set(base_path + ['v3', 'engineid', '000000000000000000000002']) self.session.set(base_path + ['v3', 'group', 'default', 'mode', 'ro']) # check validate() - a view must be created before this can be comitted with self.assertRaises(ConfigSessionError): @@ -95,9 +95,10 @@ class TestSNMPService(unittest.TestCase): self.session.commit() # create user - for authpriv in ['auth', 'privacy']: - self.session.set(base_path + ['v3', 'user', 'vyos', authpriv, 'plaintext-key', 'vyos1234']) - + self.session.set(base_path + ['v3', 'user', 'vyos', 'auth', 'plaintext-password', 'vyos12345678']) + self.session.set(base_path + ['v3', 'user', 'vyos', 'auth', 'type', 'sha']) + self.session.set(base_path + ['v3', 'user', 'vyos', 'privacy', 'plaintext-password', 'vyos12345678']) + self.session.set(base_path + ['v3', 'user', 'vyos', 'privacy', 'type', 'aes']) self.session.set(base_path + ['v3', 'user', 'vyos', 'group', 'default']) # TODO: read in config file and check values -- cgit v1.2.3