@ -82,6 +80,8 @@ public class FilterBasedLdapUserSearch implements LdapUserSearch {
@@ -82,6 +80,8 @@ public class FilterBasedLdapUserSearch implements LdapUserSearch {
@ -104,12 +104,12 @@ public class FilterBasedLdapUserSearch implements LdapUserSearch {
@@ -104,12 +104,12 @@ public class FilterBasedLdapUserSearch implements LdapUserSearch {
@ -117,42 +117,20 @@ public class FilterBasedLdapUserSearch implements LdapUserSearch {
@@ -117,42 +117,20 @@ public class FilterBasedLdapUserSearch implements LdapUserSearch {
@ -156,33 +154,35 @@ public class LdapAuthenticationProvider extends AbstractUserDetailsAuthenticatio
@@ -156,33 +154,35 @@ public class LdapAuthenticationProvider extends AbstractUserDetailsAuthenticatio
@ -55,6 +57,8 @@ public abstract class AbstractLdapAuthenticator implements LdapAuthenticator,
@@ -55,6 +57,8 @@ public abstract class AbstractLdapAuthenticator implements LdapAuthenticator,
/** The attributes which will be retrieved from the directory. Null means all attributes */
@ -137,6 +141,15 @@ public abstract class AbstractLdapAuthenticator implements LdapAuthenticator,
@@ -137,6 +141,15 @@ public abstract class AbstractLdapAuthenticator implements LdapAuthenticator,
@ -44,6 +40,7 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
@@ -44,6 +40,7 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
@ -52,9 +49,9 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
@@ -52,9 +49,9 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
// If DN patterns are configured, try authenticating with them directly
Iteratordns=getUserDns(username).iterator();
@ -66,7 +63,7 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
@@ -66,7 +63,7 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
// Otherwise use the configured locator to find the user
@ -80,18 +77,19 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
@@ -80,18 +77,19 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
Assert.isInstanceOf(LdapUserDetails.class,user,"Entry mapper must return an LdapUserDetails instance");
return(LdapUserDetails)user;
}catch(BadCredentialsExceptione){
// This will be thrown if an invalid user name is used and the method may
@ -99,24 +97,8 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
@@ -99,24 +97,8 @@ public class BindAuthenticator extends AbstractLdapAuthenticator {
if(logger.isDebugEnabled()){
logger.debug("Failed to bind as "+userDn+": "+e.getCause());
@ -62,14 +54,10 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@@ -62,14 +54,10 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@ -80,10 +68,10 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@@ -80,10 +68,10 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@ -93,13 +81,7 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@@ -93,13 +81,7 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@ -111,40 +93,36 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@@ -111,40 +93,36 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@ -162,32 +140,9 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@@ -162,32 +140,9 @@ public final class PasswordComparisonAuthenticator extends AbstractLdapAuthentic
@ -114,7 +110,7 @@ public class DefaultLdapAuthoritiesPopulator implements LdapAuthoritiesPopulator
@@ -114,7 +110,7 @@ public class DefaultLdapAuthoritiesPopulator implements LdapAuthoritiesPopulator
/** Attributes of the User's LDAP Object that contain role name information. */
privateString[]userRoleAttributes=null;
// private String[] userRoleAttributes = null;
privateStringrolePrefix="ROLE_";
@ -175,21 +171,26 @@ public class DefaultLdapAuthoritiesPopulator implements LdapAuthoritiesPopulator
@@ -175,21 +171,26 @@ public class DefaultLdapAuthoritiesPopulator implements LdapAuthoritiesPopulator
@ -199,31 +200,23 @@ public class DefaultLdapAuthoritiesPopulator implements LdapAuthoritiesPopulator
@@ -199,31 +200,23 @@ public class DefaultLdapAuthoritiesPopulator implements LdapAuthoritiesPopulator
@ -232,82 +225,60 @@ public class DefaultLdapAuthoritiesPopulator implements LdapAuthoritiesPopulator
@@ -232,82 +225,60 @@ public class DefaultLdapAuthoritiesPopulator implements LdapAuthoritiesPopulator
@ -163,13 +163,26 @@ public class FilterChainProxy implements Filter, InitializingBean,
@@ -163,13 +163,26 @@ public class FilterChainProxy implements Filter, InitializingBean,
@ -224,7 +237,7 @@ public class FilterChainProxy implements Filter, InitializingBean,
@@ -224,7 +237,7 @@ public class FilterChainProxy implements Filter, InitializingBean,
}
}
return(Filter[])list.toArray(newFilter[]{null});
return(Filter[])list.toArray(newFilter[0]);
}
/**
@ -247,9 +260,10 @@ public class FilterChainProxy implements Filter, InitializingBean,
@@ -247,9 +260,10 @@ public class FilterChainProxy implements Filter, InitializingBean,
@ -257,7 +271,7 @@ public class FilterChainProxy implements Filter, InitializingBean,
@@ -257,7 +271,7 @@ public class FilterChainProxy implements Filter, InitializingBean,
@ -33,27 +33,27 @@ public class LdapTemplateTests extends AbstractLdapServerTestCase {
@@ -33,27 +33,27 @@ public class LdapTemplateTests extends AbstractLdapServerTestCase {
@ -32,7 +32,7 @@ public class FilterBasedLdapUserSearchTests extends AbstractLdapServerTestCase {
@@ -32,7 +32,7 @@ public class FilterBasedLdapUserSearchTests extends AbstractLdapServerTestCase {
@ -45,7 +45,7 @@ public class FilterBasedLdapUserSearchTests extends AbstractLdapServerTestCase {
@@ -45,7 +45,7 @@ public class FilterBasedLdapUserSearchTests extends AbstractLdapServerTestCase {
@ -67,7 +67,7 @@ public class FilterBasedLdapUserSearchTests extends AbstractLdapServerTestCase {
@@ -67,7 +67,7 @@ public class FilterBasedLdapUserSearchTests extends AbstractLdapServerTestCase {
try{
locator.searchForUser("Ignored");
fail("Expected exception for multiple search matches.");
@ -80,7 +80,7 @@ public class FilterBasedLdapUserSearchTests extends AbstractLdapServerTestCase {
@@ -80,7 +80,7 @@ public class FilterBasedLdapUserSearchTests extends AbstractLdapServerTestCase {
@ -82,18 +83,20 @@ public class LdapAuthenticationProviderTests extends AbstractLdapServerTestCase
@@ -82,18 +83,20 @@ public class LdapAuthenticationProviderTests extends AbstractLdapServerTestCase
@ -26,12 +29,10 @@ public class BindAuthenticatorTests extends AbstractLdapServerTestCase {
@@ -26,12 +29,10 @@ public class BindAuthenticatorTests extends AbstractLdapServerTestCase {
@ -42,25 +43,36 @@ public class BindAuthenticatorTests extends AbstractLdapServerTestCase {
@@ -42,25 +43,36 @@ public class BindAuthenticatorTests extends AbstractLdapServerTestCase {
@ -27,12 +27,13 @@ public class PasswordComparisonAuthenticatorMockTests extends MockObjectTestCase
@@ -27,12 +27,13 @@ public class PasswordComparisonAuthenticatorMockTests extends MockObjectTestCase
@ -87,7 +87,7 @@ public class PasswordComparisonAuthenticatorTests extends AbstractLdapServerTest
@@ -87,7 +87,7 @@ public class PasswordComparisonAuthenticatorTests extends AbstractLdapServerTest
assertEquals("User should have 5 attributes",5,user.getAttributes().size());
@ -103,7 +103,10 @@ public class PasswordComparisonAuthenticatorTests extends AbstractLdapServerTest
@@ -103,7 +103,10 @@ public class PasswordComparisonAuthenticatorTests extends AbstractLdapServerTest
@ -119,10 +122,11 @@ public class PasswordComparisonAuthenticatorTests extends AbstractLdapServerTest
@@ -119,10 +122,11 @@ public class PasswordComparisonAuthenticatorTests extends AbstractLdapServerTest
@ -21,30 +20,39 @@ public class DefaultLdapAuthoritiesPopulatorTests extends AbstractLdapServerTest
@@ -21,30 +20,39 @@ public class DefaultLdapAuthoritiesPopulatorTests extends AbstractLdapServerTest
@ -59,9 +67,14 @@ public class DefaultLdapAuthoritiesPopulatorTests extends AbstractLdapServerTest
@@ -59,9 +67,14 @@ public class DefaultLdapAuthoritiesPopulatorTests extends AbstractLdapServerTest