@ReadOperation
    @Operation(summary = "Resolve principal attributes for user",
        parameters = @Parameter(name = "username", required = true, in = ParameterIn.PATH, description = "The username to resolve attributes for"))
    public Map<String, Object> resolvePrincipalAttributes(@Selector final String username) throws Throwable {
        val map = new HashMap<String, Object>();
        val principal = defaultPrincipalResolver.getObject().resolve(new BasicIdentifiableCredential(username));
        if (!(principal instanceof NullPrincipal)) {
            map.put("username", principal.getId());
            map.put("attributes", principal.getAttributes());
        }
        return map;
    }
Resolve principal attributes map.

@param username the uid
@return the map
@throws Throwable the throwable
support/cas-server-support-reports-core/src/main/java/org/apereo/cas/web/report/CasResolveAttributesReportEndpoint.java