Package: roundcube-core
Version: 1.6.1+dfsg-1

I tried setting up oauth2 in roundcube, but when the OIDC provider redirects back to roundcube, I get an "Oops... something went wrong!" page. When that happens, /var/log/roundcube/errors.log shows:

[09-Jul-2023 17:00:49 UTC] PHP Fatal error: Uncaught Error: Call to undefined function GuzzleHttp\json_decode() in /usr/share/roundcube/program/include/rcmail_oauth.php:237
Stack trace:
#0 /usr/share/roundcube/program/actions/login/oauth.php(37): rcmail_oauth->request_access_token()
#1 /usr/share/roundcube/index.php(198): rcmail_action_login_oauth->run()
#2 /var/lib/roundcube/public_html/index.php(26): include('...')
#3 {main}
thrown in /usr/share/roundcube/program/include/rcmail_oauth.php on line 237

Adding `require_once("GuzzleHttp/autoload.php");` to /etc/roundcube/config.inc.php seems to fix the error, but I'm not sure if that's the right way to do it. php-guzzlehttp-guzzle is installed and version 7.4.5-1 if that helps.

See also https://github.com/roundcube/roundcubemail/pull/8773 which is related, but seems to have a different cause. Presumably it will fix the issue when it makes it into Debian, but I'm filing this bug anyway in case there's a packaging issue that will prevent roundcube from finding other guzzle functions not affected by that PR.

Reply via email to