private static boolean doesCredentialFingerprintMatch(final AbstractCredential credential,
                                                          final SamlRegisteredService samlRegisteredService) {
        val fingerprint = samlRegisteredService.getSigningCredentialFingerprint();
        if (StringUtils.isNotBlank(fingerprint)) {
            val digest = DigestUtils.digest("SHA-1", Objects.requireNonNull(credential.getPublicKey()).getEncoded());
            val pattern = RegexUtils.createPattern(fingerprint, Pattern.CASE_INSENSITIVE);
            LOGGER.debug("Matching credential fingerprint [{}] against filter [{}] for service [{}]",
                digest, fingerprint, samlRegisteredService.getName());
            return pattern.matcher(digest).find();
        }
        return true;
    }
This is {@link DefaultSamlIdPObjectSigner}.

@author Misagh Moayyed
@since 5.0.0
support/cas-server-support-saml-idp-web/src/main/java/org/apereo/cas/support/saml/web/idp/profile/builders/enc/DefaultSamlIdPObjectSigner.java