From 82c405902fd3a4078a4611d55406a462049be11f Mon Sep 17 00:00:00 2001 From: Yvan Duhamel Date: Tue, 20 Feb 2024 10:05:47 +0100 Subject: [PATCH] Show the displayName of users in the people picker list by default --- .../Configuration/LDAPProviderConfiguration.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Yvand.LDAPCPSE/Yvand.LdapClaimsProvider/Configuration/LDAPProviderConfiguration.cs b/Yvand.LDAPCPSE/Yvand.LdapClaimsProvider/Configuration/LDAPProviderConfiguration.cs index 4bc6a0c..9c80646 100644 --- a/Yvand.LDAPCPSE/Yvand.LdapClaimsProvider/Configuration/LDAPProviderConfiguration.cs +++ b/Yvand.LDAPCPSE/Yvand.LdapClaimsProvider/Configuration/LDAPProviderConfiguration.cs @@ -136,6 +136,9 @@ public static ClaimTypeConfigCollection ReturnDefaultClaimTypesConfig(string cla ctConfig = new ClaimTypeConfig { ClaimType = spTrust.IdentityClaimTypeInformation.MappedClaimType }; newCTConfigCollection.Add(ctConfig); } + // By default, do the same as AD claims provider: Show the displayName of users in the people picker list + newCTConfigCollection.UserIdentifierConfig.DirectoryObjectAttributeForDisplayText = "displayName"; + //// Not adding those as additional attributes to avoid having too many LDAP attributes to search users in the LDAP filter var nonIdentityClaimTypes = ClaimsProviderConstants.GetDefaultSettingsPerUserClaimType().Where(x => x.Key != spTrust.IdentityClaimTypeInformation.MappedClaimType);