You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Has anyone got this package working locally with Docker Compose and Traefik v2? Because I've tried setting this up with the knpuniversity/oauth2-client-bundle, but I keep getting the error that the token verification failed.
IdentityProviderException
HTTP 500 Internal Server Error
invalid_token: Token verification failed
Application
I've setup the following in my Symfony 6 (PHP 8.1) app:
I've setup the client as follows and configured the Credentials with basic Client Id and Secret (no signed JWT).
When checking the events, only thing that seems different is that the first the IP address being used. The LOGIN action uses the client IP, whereas the CODE_TO_TOKEN action uses the IP of the docker container.
No idea if this is related to the token verification failing.
Debug
After trying to debug the authentication progress, I noticed that the access_token that is returned after login, is the same as the one being used to get the users info. So it hasn't changed or anything (which I could image causing the error).
It's already been 3 days of (trying) to debug this but there seems literally no similar cases to be found anywhere, so I'm out of ideas.
The text was updated successfully, but these errors were encountered:
Hey @ToshY, I'm not 100% sure but I think your proxy setting should point to your traefik instance like 'traefik:80' so you only communicate via the public url with keycloak. If this isn't helping feel free to contact me, I got a working project (php:8.1, symfony:6, keycloak:latest, traefik:2.6) but can't share it here because it's from my workplace.
Problem
Has anyone got this package working locally with Docker Compose and Traefik v2? Because I've tried setting this up with the knpuniversity/oauth2-client-bundle, but I keep getting the error that the token verification failed.
Application
I've setup the following in my Symfony 6 (PHP 8.1) app:
config\packages\framework.yaml
config\packages\knpu_oauth2_client.yaml
config\packages\security.yaml
App\Controller\KeycloakController
App\Security\KeycloakAuthenticator
Docker Compose
docker-compose.yml - app
docker-compose.yml - keycloak (16.1.0)
docker-compose.yml - traefik (2.5)
traefik.yml
dynamic/http.yml
with
proxy
set as external network.Keycloak
I've setup the client as follows and configured the
Credentials
with basicClient Id and Secret
(no signed JWT).When checking the events, only thing that seems different is that the first the IP address being used. The
LOGIN
action uses the client IP, whereas theCODE_TO_TOKEN
action uses the IP of the docker container.No idea if this is related to the token verification failing.
Debug
After trying to debug the authentication progress, I noticed that the
access_token
that is returned after login, is the same as the one being used to get the users info. So it hasn't changed or anything (which I could image causing the error).It's already been 3 days of (trying) to debug this but there seems literally no similar cases to be found anywhere, so I'm out of ideas.
The text was updated successfully, but these errors were encountered: