Score:2

Roundcube 1.5.0 upgrade: Internal Server Error

ru flag

My server updated automatically to this new release of Roundcube 1.5, since then, Roundcube don't show any Inbox mail with the message "Internal Server Error".

I tried and searched for possible solutions, but found nothing to solve.

Is a Centos 7 with PHP 7.4 and Mysql server.

Can you suggest an action plan?

user9517 avatar
cn flag
Check your logs and journal for relevant error messages.
Maicon avatar
ru flag
Wich logs you suggest? I looked dovecot and maillog in /var/log and found nothing to help
in flag
The error logs of your webserver of course. That's where the error comes from.
Score:4
ie flag

I also performed the upgrade using the complete version from the official source and I found the following error in my journal:

Oct 20 21:39:21 [hostname] roundcube[1258]: PHP Fatal error:  Uncaught Error: Class 'Spoofchecker' not found in /var/www/webmail/program/lib/Roundcube/rcube_spoofchecker.php:50
                                        Stack trace:
                                        #0 /var/www/webmail/program/actions/mail/index.php(1400): rcube_spoofchecker::check('gmail.com')
                                        #1 /var/www/webmail/program/actions/mail/index.php(523): rcmail_action_mail_index::address_string('[removed]...', 3, false, NULL, 'utf-8')
                                        #2 /var/www/webmail/program/actions/mail/list.php(123): rcmail_action_mail_index::js_message_list(Array, false, Array)
                                        #3 /var/www/webmail/program/include/rcmail.php(275): rcmail_action_mail_list->run(Array)
                                        #4 /var/www/webmail/index.php(283): rcmail->action_handler()
                                        #5 {main}
                                          thrown in /var/www/webmail/program/lib/Roundcube/rcube_spoofchecker.php on line 50

The relevant part is:

Class 'Spoofchecker' not found

This closed issue report Uncaught Error: Class 'Spoofchecker' not found #8127 suggested that the package php-intl is now a new requirement. This forum post gives more details:

According to https://bugs.php.net/bug.php?id=63790 the Spoofchecker is only available when PHP intl extension is built with ICU >= 4.2. So, I suspect your build does not have it, but it is required.

So it depends on your system, if php-intl needs to be installed. On newer systems, it is not necessary.

Installing php-intl depending on your system: Fedora/CentOS/RedHat/etc.:

dnf install php-intl

Debian/Ubuntu:

apt install php-intl

Don't forget to restart your webserver.

Maicon avatar
ru flag
Thank for your answer. I was aware about this extension and even after install the problem was not solved.
sebix avatar
ie flag
Okay, as you didn't show any logs, it was pure guesswork.
Score:3
et flag

In case using Control-WebPanel [CWP], just run these tow commands in ssh:

/scripts/update_cwp
/scripts/mail_roundcube_update

In case you install Roundcube manually, this problem will happen if you upgrade to Roundcube 1.5 version and PHP intl extension not installed and activated, so:

  1. Check the PHP version which your Roundcube run on it, to know it edit index.php which located in Roundcube path, and add this line on header of file:

echo phpinfo();

Then save file, and open url of Roundcube in browser, you will see all information about version of PHP which used by Roundcube Including php.ini path, (do not forget delete line after that).

2- Enable PHP intl Extension, the exact steps for that depends on your PHP version, many questions on Stackoverflow explain how to do that, like: how can I enable PHP Extension intl?

Maicon avatar
ru flag
Great! Your answer solved the problem. Thank you.
Score:0
jp flag

If you don't have control over your php installation, you can comment out this code in program/actions/mail/index.php to skip this:

        // Homograph attack detection (#6891)
        //if (!self::$SUSPICIOUS_EMAIL) {
        //    self::$SUSPICIOUS_EMAIL = rcube_spoofchecker::check($mailto);
        //}
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.