Package one.jpro.platform.auth.routing
Interface AuthJwtFilter
public interface AuthJwtFilter
Defines
Route filters using JWT authentication mechanism.-
Method Summary
Static MethodsModifier and TypeMethodDescriptionstatic one.jpro.platform.routing.Filtercreate(@NotNull one.jpro.platform.auth.core.jwt.JWTAuthenticationProvider authProvider, @NotNull org.json.JSONObject credentials, @NotNull String authPath, @NotNull String tokenPath, @NotNull Function<one.jpro.platform.auth.core.authentication.User, one.jpro.platform.routing.Response> userFunction, @NotNull Function<Throwable, one.jpro.platform.routing.Response> errorFunction) CreatesRoutefilter from a givenOAuth2AuthenticationProvider,OAuth2Credentialsand functions for handling successful and error cases.
-
Method Details
-
create
static one.jpro.platform.routing.Filter create(@NotNull @NotNull one.jpro.platform.auth.core.jwt.JWTAuthenticationProvider authProvider, @NotNull @NotNull org.json.JSONObject credentials, @NotNull @NotNull String authPath, @NotNull @NotNull String tokenPath, @NotNull @NotNull Function<one.jpro.platform.auth.core.authentication.User, one.jpro.platform.routing.Response> userFunction, @NotNull @NotNull Function<Throwable, one.jpro.platform.routing.Response> errorFunction) CreatesRoutefilter from a givenOAuth2AuthenticationProvider,OAuth2Credentialsand functions for handling successful and error cases.- Parameters:
authProvider- the JWT authentication providercredentials- a JSON object with the authentication informationauthPath- the authentication path for the routingtokenPath- the token pathuserFunction- operation on the given user argumenterrorFunction- operation on the given error argument- Returns:
- a
Filterobject
-