mirror of
https://github.com/spring-projects/spring-security.git
synced 2025-06-27 06:12:27 +00:00
Updated config for LdapSearch
This commit is contained in:
parent
1fa6ac0975
commit
7883aefa16
@ -4328,28 +4328,31 @@ $CATALINA_HOME/bin/startup.sh</programlisting></para>
|
|||||||
<para>
|
<para>
|
||||||
A typical configuration, using some of the beans we've discussed above, might look like this:
|
A typical configuration, using some of the beans we've discussed above, might look like this:
|
||||||
<programlisting>
|
<programlisting>
|
||||||
<bean id="initialDirContextFactory" class="org.acegisecurity.providers.ldap.DefaultInitialDirContextFactory">
|
<bean id="initialDirContextFactory"
|
||||||
|
class="org.acegisecurity.providers.ldap.DefaultInitialDirContextFactory">
|
||||||
<constructor-arg value="ldap://monkeymachine:389/dc=acegisecurity,dc=org"/>
|
<constructor-arg value="ldap://monkeymachine:389/dc=acegisecurity,dc=org"/>
|
||||||
<property name="managerDn"><value>cn=manager,dc=acegisecurity,dc=org</value></property>
|
<property name="managerDn"><value>cn=manager,dc=acegisecurity,dc=org</value></property>
|
||||||
<property name="managerPassword"><value>password</value></property>
|
<property name="managerPassword"><value>password</value></property>
|
||||||
</bean>
|
</bean>
|
||||||
|
|
||||||
<bean
|
<bean id="userSearch"
|
||||||
id="userSearch"
|
|
||||||
class="org.acegisecurity.providers.ldap.search.FilterBasedLdapUserSearch">
|
class="org.acegisecurity.providers.ldap.search.FilterBasedLdapUserSearch">
|
||||||
|
<constructor-arg index="0">
|
||||||
|
<value></value>
|
||||||
|
</constructor-arg>
|
||||||
|
<constructor-arg index="1">
|
||||||
|
<value>(uid={0})</value>
|
||||||
|
</constructor-arg>
|
||||||
|
<constructor-arg index="2">
|
||||||
|
<ref local="initialDirContextFactory" />
|
||||||
|
</constructor-arg>
|
||||||
<property name="searchSubtree">
|
<property name="searchSubtree">
|
||||||
<value>true</value>
|
<value>true</value>
|
||||||
</property>
|
</property>
|
||||||
<property name="initialDirContextFactory">
|
|
||||||
<ref local="initialDirContextFactory" />
|
|
||||||
</property>
|
|
||||||
<property name="searchFilter">
|
|
||||||
<value>(uid={0})</value>
|
|
||||||
</property>
|
|
||||||
</bean>
|
</bean>
|
||||||
|
|
||||||
<bean
|
<bean id="ldapAuthProvider"
|
||||||
id="ldapAuthProvider" class="org.acegisecurity.providers.ldap.LdapAuthenticationProvider">
|
class="org.acegisecurity.providers.ldap.LdapAuthenticationProvider">
|
||||||
<constructor-arg>
|
<constructor-arg>
|
||||||
<bean class="org.acegisecurity.providers.ldap.authenticator.BindAuthenticator">
|
<bean class="org.acegisecurity.providers.ldap.authenticator.BindAuthenticator">
|
||||||
<constructor-arg><ref local="initialDirContextFactory"/></constructor-arg>
|
<constructor-arg><ref local="initialDirContextFactory"/></constructor-arg>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user