@Override
    public AuthenticationPolicyExecutionResult isSatisfiedByInternal(final Authentication authn) {
        if (!getHandlerNames().isEmpty()) {
            val credsOk = authn.getSuccesses()
                .keySet()
                .stream()
                .anyMatch(s -> getHandlerNames().contains(s));

            if (credsOk) {
                LOGGER.warn("Excluded authentication handler(s) [{}] found in authentication attempt", getHandlerNames());
                return AuthenticationPolicyExecutionResult.failure();
            }
        }
        LOGGER.trace("Authentication policy is satisfied");
        return AuthenticationPolicyExecutionResult.success();
    }
Authentication security policy that is satisfied iff a specified
authentication handler is not part of successful authn handlers.

@author Misagh Moayyed
@since 6.3.0
core/cas-server-core-authentication-api/src/main/java/org/apereo/cas/authentication/policy/ExcludedAuthenticationHandlerAuthenticationPolicy.java