views:

141

answers:

2
<bean id="ntlmFilter" class="org.springframework.security.ui.ntlm.NtlmProcessingFilter">
    <security:custom-filter position="NTLM_FILTER" />
    <property name="stripDomain" value="true" />
    <property name="defaultDomain" value="company" />
    <property name="domainController" value="192.168.1.1" />
    <property name="authenticationManager" ref="_authenticationManager" />
</bean>

may i know how to set failover second controller?

A: 

If I understood your question properly, you are looking for a fallback authentication provider, You can setup a list of authentication managers, so that if first one fails, it will automatically check with second one.

  <security:authentication-manager alias="authenticationManager">
    <security:authentication-provider ref="ntlmServiceAuthenticationProvider"/>
    <security:authentication-provider ref="ldapAuthProvider"/>
</security:authentication-manager>
Teja Kantamneni
no, what i wanted to do is have secondary domain controller. from my xml above, currently i can only use one domain controller 192.168.1.1
cometta
+1  A: 

Unfortunately, NTLM isn't supported by Spring 3.

If using a secondary domain controller is a critical requirement for your application, I think you'll need to look into the jcifs source. Even jcifs doesn't want to support NTLM anymore either. But the old libraries are out there. I've hacked around so that my app will invisibly authenticate users whether they're from domainA or domainB. So it's possible, although possibly a bit daunting.

John