Open aabou opened 5 years ago
Can you post basic information about:
kong version 0.14.1
OIDC conf : { "created_at": 1544797168000, "config": { "response_type": "code", "realm": "kong", "redirect_after_logout_uri": "/", "scope": "openid", "token_endpoint_auth_method": "client_secret_post", "client_secret": "06d88580-51c6-4cdc-928e-537f40173408", "client_id": "kong", "bearer_only": "no", "ssl_verify": "no", "discovery": "http://localhost:8080/auth/realms/kong/.well-known/openid-configuration", "logout_path": "/logout" }, "id": "6cb8fdbe-ac45-44bb-a5c6-ce2a8f8b5261", "name": "oidc", "enabled": false }
I tried kong as a proxy for keycloak discovery url without oidc plugin and i had this kong error:
Kong Error An invalid response was received from the upstream server.
my service kong conf is:
{ "host": "localhost", "created_at": 1544797424, "connect_timeout": 60000, "id": "6f7d0692-31f0-4b77-9402-5c5d2003dc17", "protocol": "http", "name": "discovery", "read_timeout": 60000, "port": 8180, "path": "/auth/realms/kong/.well-known/openid-configuration", "updated_at": 1544797451, "retries": 5, "write_timeout": 60000, "extras": { "createdUser": null, "updatedUser": null, "kong_node_id": "1", "service_id": "6f7d0692-31f0-4b77-9402-5c5d2003dc17", "createdAt": "2018-12-14T14:23:44.476Z", "updatedAt": "2018-12-14T14:24:11.775Z", "id": 1 } }
in your opinion it can be kong or nginx issue?
Verify that the port you are using is the right one (And it seems it is, 8080 regularly is the one for Keycloak), but also try to find what is the IP used by your Keycloak server. If you are using a Docker container, try something like
docker inspect <id of the container>
and checkout NetworkSettings.Networks.IPAddress
.
Hello @Trojan295 or oidc-Group,
At the moment of discovery my kong can't decode json response (for information i use keycloak).
`[error] 3904#0: *396225 [lua] openidc.lua:497: openidc_discover(): could not decode JSON from Discovery data: response indicates failure, status=302, body=
302 Found
`
Thanks in avance guys,