// null out the credentials
opContext.setCredentials( null );
}
// pick the first matching authenticator type
AuthenticationLevel level = opContext.getAuthenticationLevel();
if ( level == AuthenticationLevel.UNAUTHENT )
{
// This is a case where the Bind request contains a DN, but no password.
// We don't check the DN, we just return a UnwillingToPerform error
// Cf RFC 4513, chap. 5.1.2
throw new LdapOperationNotSupportedException( "Cannot Bind for DN " + opContext.getDn().getUpName(), ResultCodeEnum.UNWILLING_TO_PERFORM );
}
Collection<Authenticator> authenticators = getAuthenticators( level.getName() );
if ( authenticators == null )
{
LOG.debug( "No authenticators found, delegating bind to the nexus." );