SOLVED Roundcube Webmail - error "Could not load message from server"

JIKOmetrix

Well-Known Member
Apr 3, 2007
235
46
178
Hello,

I have some roundcube webmail users that cannot see certain emails. When attempting to view the message in roundcube it simply says "Could not load message from server".

I found this [SOLVED] Roundcube 1.0.3 An error occurred! Could not load message from server.

I edited line 2852 in /usr/local/cpanel/base/3rdparty/roundcube/program/lib/Roundcube/rcube_imap_generic.php file from $binary = true; to $binary = false;

Then saved the file and now the users that had this error on some messages are able to view the messages without error.

That fine for testing. However,
1) why would this fix the issue with only certain emails from G Suite
and
2) how do I make this a permanent fix? You know cPanel update will overwrite this change we will get the complaints again.

Any suggestions would be great.

Thanks,
Mike
 
Last edited by a moderator:

cPRex

Jurassic Moderator
Staff member
Oct 19, 2014
14,235
2,217
363
cPanel Access Level
Root Administrator
Hey there! When looking at the larger section of that code, I see this:

Code:
 * Fetches body of the specified message part
     */
    public function handlePartBody($mailbox, $id, $is_uid = false, $part = '', $encoding = null, $print = null,
        $file = null, $formatted = false, $max_bytes = 0)
    {
        if (!$this->select($mailbox)) {
            return false;
        }

        $binary    = true;
        $initiated = false;
so if I'm reading that right, this is how Roundcube interprets the body data. If the issue is only happening with messages sent from Gsuite, I wonder if those specific messages have the wrong encoding.

The only way to keep that change would be a post-upcp script or cron that does it for you, as that will get overwritten.
 

JIKOmetrix

Well-Known Member
Apr 3, 2007
235
46
178
Yes, that is the location of the code that is changed.

I was thinking the same thing. It does not happen with all messages. It only seem to happen with certain message like google calendar or messages with attachments, but not all of them from g Suite. The same messages that cannot be read by roundCube, throw an error for Horde too, but can be read by iPhone apple mail or desktop apple mail. I have not tested outlook.

I'm feeling stuck, but I guess I can setup a cron with bash and sed. Not idea though.
 

JIKOmetrix

Well-Known Member
Apr 3, 2007
235
46
178
I looked at an EML of one of the messages that could not load. It looks like any other message with multi-part separation. I cannot post here since the messages are private for a healthcare worker. My luck I'd break some HIPPA rules. The only difference see between a gmail message the messages the create this read error with roundcude only not other mail clients is a header entry "X-Encrypted-Email: This email was sent using 256-bit AES encryption by Paubox". I think this is only in transit encryption.
 

JIKOmetrix

Well-Known Member
Apr 3, 2007
235
46
178
Hello,

JohnDoh from roundcube forum said:

Some IMAP servers have buggy implementations of the BINARY extension. You can disable Roundcube from using it by setting
Code: [Select]
$config['imap_disabled_caps'] = ['BINARY'];
in your Roundcube config file.

Do you know if the Roundcube config file is overwritten with updates too?
 

JIKOmetrix

Well-Known Member
Apr 3, 2007
235
46
178
I would expect the Roundcube configuration to get overwritten with updates also, as we do provide updates to that piece of software.
So far the Roundcube configuration is saying ad configured and the cpanel scripted did detect modification to the rcube_imap_generic.php file and would not overwrite it. Notifaction email gave instructions on how to return the modified file to default settings. I did this and the Roundcube configuration file changes continue to be presistant.
 
  • Like
Reactions: cPRex

JIKOmetrix

Well-Known Member
Apr 3, 2007
235
46
178
Probably not - we're actually looking to start the process of dropping Horde since the last release was over two years ago, so it doesn't receive any security updates.
Yeah, that is a good reason to drop horde. To bad. It was nice while it lasted.
 
  • Like
Reactions: cPRex