-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug: apisix openid plugin - how the logout path does work ? #6345
Comments
thanks for your detailed report, @starsz do you have time to dig this? |
Hi, @MirtoBusico.Thanks for your detailed report.
Can you have a try for another URL like https://www.m01.net/v1/xxx ? Because you had config the |
Well,
the login screen appear, I can login and then I receive a 404 error
But now the user is authenticated and if I try
it works correctly It seems I don't understand how to use this plugin as explained here
What I'm trying to do is
I don't know how to do this |
UPDATE
|
UPDATE2
Now the access sequence and results are:
but the user is correctly logged out I don't know how to cerrctly redirect the logout page |
Hi @MirtoBusico . Thanks for your patient test. You can refer to the config of the APISIX OpenID-Connect Plugin. There is a logout_path in the config. |
Seems I don't understand the documentation Setting teh logout_path to "/logout" (that should be the default) I'm redirect to
and the user is logged out |
Oh.If this, I think it's a bug. Let me have a try. |
Hi, @MirtoBusico.I had tested it on my local env. It looks good. |
Yes, I'm trying to setup a different logout route that don't use the openid connect. |
Well, with the new framework I'm not able to complete the login redirect.
All routes use an httpbin service as upstream The first route definition is
The second route definition is
The first route works (the httpbin home page is partially shown - other parts of the page that have a path different from "/" are not served by the route) Adding to the second route this openid-connect definition
Now trying to access the url "https://www.m01.net/user/headers" shows the keycloak login page, executes the login, but I receive an error
on this redirected urt
In the apisix log I see
Mybe there is a conflict with the proxy-rewrite plugin Now I'll try to find an echo program to replace httpbin so to avoid the rewite rules |
Hi @starsz another try and the first results: wrong redirect on logout (so seems that there is a proxy-rewrite conflict) I created two routes:
All routes use an httpbin service as upstream The first route definition is
The second route definition is
Now
In the apisix log I see
Maybe it is a keycloak installation or version problem? I'm using keycloak on a virtual machine separated from the kubernetes cluster What is your test configuration? |
But the user is logout. If you access https://www.m01.net/headers, it will show the keycloak login page. So do you mean we can config a logout_redirect_url? Then we can redirect the logout_redirect_url. |
Thanks |
Issue description
I'm trying to use a keycloak server for user authentication (and authorization) in Apisix installed in a kubernetes cluster along with Istio
My keycloak server replies to
The keycloak certificate is signed by my private Certification Authority (CA)
My plugin setup followed these articles:
The definition is correct; but when I try to access a route with openid plugin enabled i receive an 500 internal error
Trying to access the keycloak server from the apisix pod shell I see that the CA is not recognized
Environment
apisix version
):uname -a
):nginx -V
oropenresty -V
):curl http://127.0.0.1:9090/v1/server_info
to get the info from server-info API):luarocks --version
):Steps to reproduce
with the dashboard create an SSL resource with key and certificate for www.m02.net
Create a route and an upstream for www.m01.net pointing to the httpbin service. Verify that the URL "https://www.m01.net" works correctly
setup the openid connect plugin for the route following thew instructions at
Looking at the apisix log you see:
Trying to access the keycloak server from the apisix pod you see that the CA is not recognized (" SSL certificate problem: unable to get local issuer certificate")
Actual result
Trying to access "https://www.m01.net" and receive a "500 Internal Server Error"
Error log
Looking at the apisix log you see:
Trying to access the keycloak server from the apisix pod you see that the CA is not recognized (" SSL certificate problem: unable to get local issuer certificate")
Expected result
The keycloak login page should show up and after login the httpbin page is shown
The text was updated successfully, but these errors were encountered: