@Override
    public String[] resolveFrom(final JoinPoint auditableTarget, final Object retval) {
        Objects.requireNonNull(retval, "Return value must not be null");
        val result = (AuditableExecutionResult) retval;
        val accessCheckOutcome = "Client Access " + BooleanUtils.toString(result.isExecutionFailure(), "Denied", "Granted");

        val values = new HashMap<>();
        values.put("result", accessCheckOutcome);
        if (result.getProperties().containsKey(Client.class.getSimpleName())) {
            values.put("client", result.getProperties().get(Client.class.getSimpleName()));
        }
        result.getRegisteredService().ifPresent(service ->
            values.put("registeredService", service.getName() + ':' + service.getServiceId()));
        result.getService().ifPresent(service -> values.put("service", service.getId()));
        return new String[]{auditFormat.serialize(values)};
    }
This is {@link DelegatedAuthenticationAuditResourceResolver}.

@author Misagh Moayyed
@since 5.3.0
support/cas-server-support-pac4j-core/src/main/java/org/apereo/cas/audit/DelegatedAuthenticationAuditResourceResolver.java