@Override
    protected Map<String, List<Object>> getAttributesForSamlRegisteredService(
        final Map<String, List<Object>> attributes,
        final SamlRegisteredServiceCachingMetadataResolver resolver,
        final SamlRegisteredServiceMetadataAdaptor facade,
        final EntityDescriptor entityDescriptor,
        final RegisteredServiceAttributeReleasePolicyContext context) {

        LOGGER.trace("Loading entity attribute predicate filter for candidate [{}] with values [{}]",
            getEntityAttribute(), getEntityAttributeValues());
        val match = SamlIdPUtils.doesEntityDescriptorMatchEntityAttribute(entityDescriptor,
            List.of(MetadataEntityAttributeQuery.of(getEntityAttribute(), getEntityAttributeFormat(), getEntityAttributeValues())));
        if (match) {
            LOGGER.debug("Authorizing release of allowed attributes [{}] for entity id [{}]",
                attributes, entityDescriptor.getEntityID());
            return authorizeReleaseOfAllowedAttributes(context, attributes);
        }
        LOGGER.debug("Unable to authorize attribute release for entity attribute category [{}] and value(s) [{}] to entity id [{}]",
            getEntityAttribute(), getEntityAttributeValues(), entityDescriptor.getEntityID());
        return new HashMap<>();
    }
This is {@link MetadataEntityAttributesAttributeReleasePolicy}.

@author Misagh Moayyed
@since 5.2.0
support/cas-server-support-saml-idp-core/src/main/java/org/apereo/cas/support/saml/services/MetadataEntityAttributesAttributeReleasePolicy.java