Package com.linecorp.armeria.server.auth
Interface AuthFailureHandler
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A callback which is invoked to handle an authorization failure indicated by
Authorizer
.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionauthFailed
(HttpService delegate, ServiceRequestContext ctx, HttpRequest req, @Nullable Throwable cause) Invoked when the authorization of the specifiedHttpRequest
has failed.
-
Method Details
-
authFailed
@CheckReturnValue HttpResponse authFailed(HttpService delegate, ServiceRequestContext ctx, HttpRequest req, @Nullable @Nullable Throwable cause) throws Exception Invoked when the authorization of the specifiedHttpRequest
has failed.- Parameters:
delegate
- the nextService
in the decoration chainctx
- theServiceRequestContext
req
- theHttpRequest
being handledcause
-null
if theHttpRequest
has been rejected by theAuthorizer
. non-null
if theAuthorizer
raised anException
.- Throws:
Exception
-