I have a Quarkus microservice doing authentication and authorization with Keycloak using quarkus-oidc and quarkus-keycloak-authorization extensions.
I need to additionally implement following two request interceptors/filters:
- A filter before any auth logic kicks in. This is to copy token from query param to header (required for web sockets). What should be the priority of this filter?
- A filter to have custom authorization logic. This should be executed after all authentication and keycloak authorization logic but just before API execution? What should be priority of this filter?
I tried putting @Priority(Interceptor.Priority.PLATFORM_BEFORE) and @Prematching also to my filter, but even this is being called after OIDC kicks in.
Also, is there any way to support extending quarkus oidc logic to include custom code?
I am unable to get the priority of oidc and keycloak-auth interceptors (knowing these could help me deciding the priority of my filters). Please help.