spring-application-ldap.xml
1.02 KB
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd">
<bean id="ldapContextSource" class="com.ui.ldaputil.YhLdapContextSource">
<!--test ldaps://yoho01.local:636 -->
<!--formal ldaps://ldap.yoho.cn:2018 -->
<property name="url" value="ldaps://ldap.yoho.cn:2018"/>
<property name="base" value="dc=yoho01,dc=local"/>
<property name="userDn" value="tech@yoho01.local"/>
<property name="password" value="3nIiz2Ov38NU"/>
<property name="referral" value="follow"></property>
</bean>
<bean id="ldapTemplate" class="org.springframework.ldap.core.LdapTemplate">
<property name="contextSource" ref="ldapContextSource"/>
<property name="ignorePartialResultException" value="true"/>
</bean>
</beans>