protected void validateAuthnContextClassRefs(final SAML2MessageContext context, final List<String> providedAuthnContextClassRefs) {
        var configContext = context.getConfigurationContext();
        if (!configContext.getAuthnContextClassRefs().isEmpty()) {
            logger.debug("Required authentication context class refs are {}", configContext.getAuthnContextClassRefs());
            logger.debug("Found authentication context class refs are {}", providedAuthnContextClassRefs);

            var results = configContext.getAuthnContextClassRefs().stream()
                .distinct()
                .filter(providedAuthnContextClassRefs::contains)
                .collect(Collectors.toSet());
            if (results.size() != configContext.getAuthnContextClassRefs().size()) {
                throw new SAMLAuthnContextClassRefException("Requested authentication context class refs do not match "
                    + " those in authentication statements from IDP.");
            }
        }
    }
<p>validateAuthnContextClassRefs.</p>

@param context a {@link SAML2MessageContext} object
@param providedAuthnContextClassRefs a {@link List} object
pac4j-saml/src/main/java/org/pac4j/saml/sso/impl/SAML2AuthnResponseValidator.java