@Override
public AuthenticationResponse authenticate(
final AuthenticationIdentity identity) throws RepositoryLoginException,
RepositoryException {
if (adGroupsAuthenticationManager != null) {
return authenticateAgainstActiveDirectory(new MutableIdentity(identity));
} else {
return authenticateAgainstSharepoint(identity);
}
}