diff options
author | Viacheslav Hletenko <v.gletenko@vyos.io> | 2022-12-04 13:29:00 +0000 |
---|---|---|
committer | Viacheslav Hletenko <v.gletenko@vyos.io> | 2022-12-04 13:29:00 +0000 |
commit | 7ce6ad4486912dc76c5999f420897efe2747cabb (patch) | |
tree | 2e893561509b454988d0a890f661032fe51ff344 /src | |
parent | 1804f1cb1a9026fe07b49f5d65460875423534bc (diff) | |
download | vyos-1x-7ce6ad4486912dc76c5999f420897efe2747cabb.tar.gz vyos-1x-7ce6ad4486912dc76c5999f420897efe2747cabb.zip |
T4860: Verify if mode in openconnect ocserv dict
openconnect authentication mode must be set
check dict that 'mode' exists in openconnect authentication
Diffstat (limited to 'src')
-rwxr-xr-x | src/conf_mode/vpn_openconnect.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/conf_mode/vpn_openconnect.py b/src/conf_mode/vpn_openconnect.py index c050b796b..845250dd4 100755 --- a/src/conf_mode/vpn_openconnect.py +++ b/src/conf_mode/vpn_openconnect.py @@ -58,7 +58,7 @@ def get_config(): default_values = defaults(base) ocserv = dict_merge(default_values, ocserv) - if "local" in ocserv["authentication"]["mode"]: + if 'mode' in ocserv["authentication"] and "local" in ocserv["authentication"]["mode"]: # workaround a "know limitation" - https://phabricator.vyos.net/T2665 del ocserv['authentication']['local_users']['username']['otp'] if not ocserv["authentication"]["local_users"]["username"]: |