Skip to content
Snippets Groups Projects
Commit 52f05e6d authored by Thomas Schneider's avatar Thomas Schneider
Browse files

Fix LDAP displayName encoding also for login

parent f871f94a
No related branches found
No related tags found
1 merge request!1Fix LDAP displayName encoding also for login
Pipeline #4270 passed
...@@ -47,8 +47,18 @@ Set($ExternalSettings, { ...@@ -47,8 +47,18 @@ Set($ExternalSettings, {
'attr_map' => { 'attr_map' => {
'Name' => 'sAMAccountName', 'Name' => 'sAMAccountName',
'EmailAddress' => 'mail', 'EmailAddress' => 'mail',
'RealName' => 'displayName', 'RealName' => sub {
use Encode qw(decode);
my %args = @_;
my @values = grep defined && length,
$args{'external_entry'}->get_value('displayName');
foreach my $v (@values) {
$v = decode('UTF-8', $v);
}
return @values;
},
}, },
'net_ldap_args' => [raw => qr/(displayName)/],
}, },
}); });
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment