public static List<? extends PersonAttributeDao> newRestAttributeRepository(final List<RestPrincipalAttributesProperties> properties) {
        return properties
            .stream()
            .filter(rest -> StringUtils.hasText(rest.getUrl()))
            .map(rest -> {
                val dao = new RestfulPersonAttributeDao();
                dao.setOrder(rest.getOrder());
                FunctionUtils.doIfNotNull(rest.getId(), id -> dao.setId(id));
                dao.setUrl(rest.getUrl());
                dao.setMethod(Objects.requireNonNull(HttpMethod.valueOf(rest.getMethod())).name());
                dao.setEnabled(rest.getState() != AttributeRepositoryStates.DISABLED);

                val headers = CollectionUtils.<String, String>wrap(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON_VALUE);
                headers.putAll(rest.getHeaders());
                dao.setHeaders(headers);
                dao.setUsernameAttributeProvider(new SimpleUsernameAttributeProvider(rest.getUsernameAttribute()));
                dao.putTag("state", rest.getState());

                if (StringUtils.hasText(rest.getBasicAuthPassword()) && StringUtils.hasText(rest.getBasicAuthUsername())) {
                    dao.setBasicAuthPassword(rest.getBasicAuthPassword());
                    dao.setBasicAuthUsername(rest.getBasicAuthUsername());
                    LOGGER.debug("Basic authentication credentials are located for REST endpoint [{}]", rest.getUrl());
                } else {
                    LOGGER.debug("Basic authentication credentials are not defined for REST endpoint [{}]", rest.getUrl());
                }
                return dao;
            })
            .toList();
    }
New rest attribute repository list.

@param properties the properties
@return the list
support/cas-server-support-person-directory-core/src/main/java/org/apereo/cas/persondir/PersonDirectoryUtils.java