Interface SecurityResponseMapper

Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface @Contract public interface SecurityResponseMapper
A SecurityResponse mapper that is called when a security error is encountered. Gives a chance for applications to craft a more informative response to the user as to the cause of the error.

Note that this service is ONLY used for Helidon Declarative (annotation based) endpoints

  • Method Summary

    Modifier and Type
    Method
    Description
    aborted(ServerResponse serverResponse, SecurityResponse securityResponse, String message)
    Called when a security response is aborted due to a security problem (e.g.
  • Method Details

    • aborted

      String aborted(ServerResponse serverResponse, SecurityResponse securityResponse, String message)
      Called when a security response is aborted due to a security problem (e.g. authentication failure). Handles control to the application to construct the response returned to the client. Security providers can provide context to mappers using the Helidon context mechanism.
      Parameters:
      serverResponse - the web server response (never call ServerResponse.send(java.lang.Object) as part of handling; return appropriate return message
      securityResponse - the security response
      message - message to be written to the response
      Returns:
      new message to be written to the response, never null
      See Also: