Class HttpStatusDecisionMapper

java.lang.Object
com.svenruppert.jsentinel.rest.HttpStatusDecisionMapper

public final class HttpStatusDecisionMapper extends Object
Maps semantic authorization decisions to generic HTTP response behavior.
  • Field Details

    • STEP_UP_SCHEME

      public static final String STEP_UP_SCHEME
      Auth scheme used in the WWW-Authenticate header when an adapter challenges for a step-up. The full header value follows RFC 7235 syntax: StepUp method="<method>". The method parameter carries the mechanism token (e.g. MFA, REAUTH) lifted from AuthorizationDecision.StepUpRequired.method().
      See Also:
  • Constructor Details

    • HttpStatusDecisionMapper

      public HttpStatusDecisionMapper()
  • Method Details

    • apply

      public boolean apply(com.svenruppert.jsentinel.authorization.api.AuthorizationDecision decision, RestResponse response)
      Applies a decision to the response.
      Parameters:
      decision - decision
      response - response
      Returns:
      true if the protected handler may continue