protected SignatureSigningParameters buildSignatureSigningParameters(final RoleDescriptor descriptor,
                                                                         final SamlRegisteredService service) {
        return FunctionUtils.doUnchecked(() -> {
            val criteria = new CriteriaSet();
            val signatureSigningConfiguration = getSignatureSigningConfiguration(service);
            criteria.add(new SignatureSigningConfigurationCriterion(signatureSigningConfiguration));
            criteria.add(new RoleDescriptorCriterion(descriptor));

            val resolver = new SAMLMetadataSignatureSigningParametersResolver();
            LOGGER.trace("Resolving signature signing parameters for [{}]", descriptor.getElementQName().getLocalPart());
            val params = resolver.resolveSingle(criteria);
            if (params != null) {
                LOGGER.trace("""
                        Created signature signing parameters.
                        Signature algorithm: [{}]
                        Signature canonicalization algorithm: [{}]
                        Signature reference digest methods: [{}]
                        Signature reference canonicalization algorithm: [{}]""",
                    params.getSignatureAlgorithm(),
                    params.getSignatureCanonicalizationAlgorithm(),
                    params.getSignatureReferenceDigestMethod(),
                    params.getSignatureReferenceCanonicalizationAlgorithm());
            } else {
                LOGGER.warn("Unable to resolve SignatureSigningParameters, response signing will fail."
                    + " Make sure domain names in IDP metadata URLs and certificates match CAS domain name");
            }
            return params;
        });
    }
Build signature signing parameters signature signing parameters.

@param descriptor the descriptor
@param service    the service
@return the signature signing parameters
support/cas-server-support-saml-idp-web/src/main/java/org/apereo/cas/support/saml/web/idp/profile/builders/enc/DefaultSamlIdPObjectSigner.java