diff options
author | Christian Poessinger <christian@poessinger.com> | 2020-08-20 05:51:39 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-20 05:51:39 +0200 |
commit | 106073a1899fcc781a929438df40b5b29433eb3d (patch) | |
tree | d09689f2c8e8263072c0b5456e1788c49338ea4f /src/conf_mode/vpn_anyconnect.py | |
parent | c7707363bd9b44f9dd9bf460247f350a05b3f5fb (diff) | |
parent | 9627888b89ddb712eec06a19bcc149367e8c3036 (diff) | |
download | vyos-1x-106073a1899fcc781a929438df40b5b29433eb3d.tar.gz vyos-1x-106073a1899fcc781a929438df40b5b29433eb3d.zip |
Merge pull request #530 from DmitriyEshenko/1x-anyconnect-fix01
anyconnect: T2811: Return None if anyconnect not configured
Diffstat (limited to 'src/conf_mode/vpn_anyconnect.py')
-rwxr-xr-x | src/conf_mode/vpn_anyconnect.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/conf_mode/vpn_anyconnect.py b/src/conf_mode/vpn_anyconnect.py index 45c06bffa..158e1a117 100755 --- a/src/conf_mode/vpn_anyconnect.py +++ b/src/conf_mode/vpn_anyconnect.py @@ -43,6 +43,9 @@ def get_hash(password): def get_config(): conf = Config() base = ['vpn', 'anyconnect'] + if not conf.exists(base): + return None + ocserv = conf.get_config_dict(base, key_mangling=('-', '_'), get_first_key=True) default_values = defaults(base) ocserv = dict_merge(default_values, ocserv) |