From ab95f749dce84813a2cb442c9001f3dc8ec3a3d9 Mon Sep 17 00:00:00 2001 From: Christophe Maudoux Date: Fri, 3 May 2019 17:17:13 +0200 Subject: [PATCH] Append warning if Impersonation is enable without prefix (#1664) --- .../lib/Lemonldap/NG/Manager/Conf/Tests.pm | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Conf/Tests.pm b/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Conf/Tests.pm index b3819f856..b1c502631 100644 --- a/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Conf/Tests.pm +++ b/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Conf/Tests.pm @@ -642,6 +642,16 @@ sub tests { # Return return 1; }, + + # Warn if Impersonation is enabled without prefix + impersonationPrefix => sub { + return 1 unless ( $conf->{impersonationRule} ); + return ( 1, "Impersonation is enabled without real attributes prefix" ) + unless ( $conf->{impersonationPrefix} ); + + # Return + return 1; + }, }; }