java - Spring-security-ldap fails to authenticate non-administrative users using active directory LDAP - Stack Overflow

Good morning, in the past I have developed applications in Node.js using the activedirectory and active

Good morning, in the past I have developed applications in Node.js using the activedirectory and activedirectory2 modules, and with both modules, the webapps can authenticate users using the AD LDAP. Both administrator users and normal users.

These days I am developing an application with the Spring Framework, and I am using the class .springframework.security.ldap.authentication.ad.ActiveDirectoryLdapAuthenticationProvider.

With this class, only users in the Active Directory Administrator group can authenticate, not other users. Can you tell me why?

The domain controller is a Windows Server 2022.

This is my xml configuration:

<bean id="adAuthenticationProvider"
              class=".springframework.security.ldap.authentication.
              ad.ActiveDirectoryLdapAuthenticationProvider">

  <constructor-arg value="example" />
  <constructor-arg value="ldap://dc.example:3268" />
  <constructor-arg value="ou=ORG,dc=example,dc=com" />
  <property name="convertSubErrorCodesToExceptions" value=*"true"/>

</bean>

<security:http >
  <security:csrf disabled = "true"/>
  <security:intercept-url pattern=*"/**"* access=*"isAuthenticated()" />
  <security:form-login />
  <security:logout />
</security:http>

<security:authentication-manager>
  <security:authentication-provider ref="adAuthenticationProvider"/>
  </security:authentication-manager>
</beans>

I tried changing permissions on ad, changing OUs, changing the configuration multiple times but nothing works.

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745572277a4633751.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信