From 42a0639bb502e3586f65b735ead3288e590f5fdb Mon Sep 17 00:00:00 2001 From: Ozzie Isaacs Date: Thu, 23 Jul 2020 19:23:57 +0200 Subject: [PATCH] Fix #1533 (Invalid LDAP Cert Path no longer crashes app) --- cps/services/simpleldap.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cps/services/simpleldap.py b/cps/services/simpleldap.py index 0933a933..336b0f2c 100644 --- a/cps/services/simpleldap.py +++ b/cps/services/simpleldap.py @@ -65,7 +65,10 @@ def init_app(app, config): app.config['LDAP_GROUP_OBJECT_FILTER'] = config.config_ldap_group_object_filter app.config['LDAP_GROUP_MEMBERS_FIELD'] = config.config_ldap_group_members_field - _ldap.init_app(app) + try: + _ldap.init_app(app) + except RuntimeError as e: + log.error(e) def get_object_details(user=None, group=None, query_filter=None, dn_only=False):