-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
OAuth2 check token validity / trigger refresh from plugin #8224
Comments
I suppose we should do a refresh in |
Now also checking/refreshing access token in |
Hello,
I guess this happens if the user leaves the browser session idle for more than 30min... is that correct ? Thanks |
Hello,
I have added support to the rcmcarddav plugin to allow using the access token acquired by roundcube to authenticate with CardDAV servers. Now I noticed that when I stay inside the addressbook task for a couple of minutes, the access token expires and I start getting connection errors. Looking at the code of roundcube, the token refresh is triggered upon connection to the imap, smtp, or managesieve services. I guess none of those is invoked while in the addressbook task. However, the check_token_validity function is protected, so I cannot call it from rcmcarddav. I could call one of the hook functions like
rcmail_oauth::storage_init()
, but that would be a hack.What is the suggested method to trigger the token refresh if needed from a plugin? Even for managesieve, which is a plugin, the refresh is hard coded into the roundcube core, not part of the plugin code.
The text was updated successfully, but these errors were encountered: