[pve-devel] [PATCH common] Added 'raw' option to LDAP constructor for UTF8 string default decoding

Ådne Hovda ahovda at openit.com
Mon Feb 8 13:32:11 CET 2021


---

Notes:
    When syncing users including given/surname with non-ASCII characters from Active Directory I found garbled text in the users list in the GUI. Adding this option to the Net::LDAP object solved the issue.

 src/PVE/LDAP.pm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/PVE/LDAP.pm b/src/PVE/LDAP.pm
index ff98e36..5fa43a8 100644
--- a/src/PVE/LDAP.pm
+++ b/src/PVE/LDAP.pm
@@ -23,6 +23,7 @@ sub ldap_connect {
 	port => $port,
 	timeout => 10,
 	onerror => 'die',
+	raw => qr/(;binary)/,
     );
 
     my $hosts = [];
-- 
2.29.2





More information about the pve-devel mailing list