Browse Source

Tidying.

2.0.x
Luke Taylor 19 years ago
parent
commit
32038d8b92
  1. 11
      core/src/main/java/org/springframework/security/ldap/SpringSecurityAuthenticationSource.java

11
core/src/main/java/org/springframework/security/ldap/SpringSecurityAuthenticationSource.java

@ -10,11 +10,11 @@ import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
/** /**
* An AuthenticationSource to retrieve authentication information stored in Spring Security's
* {@link SecurityContextHolder}.
* <p>
* This is a copy of Spring LDAP's AcegiAuthenticationSource, updated for use with Spring Security 2.0. * This is a copy of Spring LDAP's AcegiAuthenticationSource, updated for use with Spring Security 2.0.
* *
* An AuthenticationSource to retrieve authentication information stored in
* Spring Security's {@link SecurityContextHolder}.
*
* @author Mattias Arthursson * @author Mattias Arthursson
* @author Luke Taylor * @author Luke Taylor
* @since 2.0 * @since 2.0
@ -33,8 +33,7 @@ public class SpringSecurityAuthenticationSource implements AuthenticationSource
Authentication authentication = SecurityContextHolder.getContext().getAuthentication(); Authentication authentication = SecurityContextHolder.getContext().getAuthentication();
if (authentication == null) { if (authentication == null) {
log.warn("No Authentication object set in SecurityContext - " log.warn("No Authentication object set in SecurityContext - returning empty String as Principal");
+ "returning empty String as Principal");
return ""; return "";
} }
@ -54,7 +53,7 @@ public class SpringSecurityAuthenticationSource implements AuthenticationSource
} }
} }
/* /**
* @see org.springframework.ldap.core.AuthenticationSource#getCredentials() * @see org.springframework.ldap.core.AuthenticationSource#getCredentials()
*/ */
public String getCredentials() { public String getCredentials() {

Loading…
Cancel
Save