This is an automated email from the ASF dual-hosted git repository.
benjobs pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/incubator-streampark.git
The following commit(s) were added to refs/heads/dev by this push:
new b919774ef [BUG] fix ldap login error (#2774)
b919774ef is described below
commit b919774ef79b01a416f4b0e6649152691b871590
Author: zhoulii <[email protected]>
AuthorDate: Mon May 29 22:22:29 2023 +0800
[BUG] fix ldap login error (#2774)
Co-authored-by: zhoulii <[email protected]>
---
.../apache/streampark/console/system/security/impl/LdapService.java | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git
a/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/system/security/impl/LdapService.java
b/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/system/security/impl/LdapService.java
index bcbc573eb..2eb0043a4 100644
---
a/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/system/security/impl/LdapService.java
+++
b/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/system/security/impl/LdapService.java
@@ -82,11 +82,12 @@ public class LdapService {
ldapEnv = new Properties();
ldapEnv.put(Context.INITIAL_CONTEXT_FACTORY,
"com.sun.jndi.ldap.LdapCtxFactory");
ldapEnv.put(Context.SECURITY_AUTHENTICATION, "simple");
- ldapEnv.put(Context.SECURITY_PRINCIPAL, ldapSecurityPrincipal);
- ldapEnv.put(Context.SECURITY_CREDENTIALS, ldapPrincipalPassword);
ldapEnv.put(Context.PROVIDER_URL, ldapUrls);
}
+ ldapEnv.put(Context.SECURITY_PRINCIPAL, ldapSecurityPrincipal);
+ ldapEnv.put(Context.SECURITY_CREDENTIALS, ldapPrincipalPassword);
+
try {
LdapContext ctx = new InitialLdapContext(ldapEnv, null);
SearchControls sc = new SearchControls();