refactor: 判断是否是ldaps不区分大小写

This commit is contained in:
Captain.B 2020-10-30 15:58:29 +08:00
parent 41df7ed375
commit 8fc99f8514

View File

@ -147,7 +147,7 @@ public class LdapService {
String credentials = EncryptUtils.aesDecrypt(password).toString();
LdapContextSource sourceLdapCtx;
if (StringUtils.startsWith(url, "ldaps://")) {
if (StringUtils.startsWithIgnoreCase(url, "ldaps://")) {
sourceLdapCtx = new SSLLdapContextSource();
// todo 这里加上strategy 会报错
// DefaultTlsDirContextAuthenticationStrategy strategy = new DefaultTlsDirContextAuthenticationStrategy();