Closed bbigras closed 4 years ago
This issue occurs when the OIDC (oAuth2) token is expired while the nginx-sso cookie is still valid. Then the old token is sent to the server and the server does not respond with HTTP 401 but HTTP 400 (in v0.22.0
a fix was added for HTTP 401 not being handled).
Which provider are you using the OIDC module with?
Which provider are you using the OIDC module with?
One of the worst one ever. https://wordpress.org/plugins/oauth2-provider/
There's only 2 plugins to make wordpress act as an oauth server...
I've drafted a PR (#52) for this and updated the luzifer/nginx-sso:experimental
docker image with that PR. Please have a look whether this solves the issue you are experiencing?
Sorry for the late reply, I was waiting to get back to work to test.
I'm currently running 69c7f91be221168c4d892fa014a68f3a1e37dcde but I don't know how long it takes for the tokens to expire.
I'll set a reminder to test every day.
Thanks for you time.
I think the problem is gone with your fix.
The wp plugin's token expire very fast so I think I was able to test it every time I tried.
In that case v0.24.0
including this patch is out now! Thanks for testing out the patch! :slightly_smiling_face:
nginx-sso-0.22.0
I got this error:
I deleted my cookies and it was working again. It's possible that the problem is caused by the bad oauth server I use but would it be possible to make the user log in again if that error happens?
EDIT: I forgot to say that when this error happens, the user only gets a 500 error page. That's why I wanted the login to try again. But maybe that could cause an infinite loop.