diff --git a/CHANGELOG b/CHANGELOG index 2a75a246e..fc502ae77 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -45,6 +45,7 @@ CHANGELOG Roundcube Webmail - Enigma: Fix bug where revoked users/keys were not greyed out in key info - Enigma: Fix error message when trying to encrypt with a revoked key (#6607) - Enigma: Fix "decryption oracle" bug [CVE-2019-10740] (#6638) +- Enigma: Fix bug where signature verification could have been skipped for some message structures (#6838) - Fix css styles leak from replied/forwarded message to the rest of the composed text (#6831) - Fix invalid path to "add contact" icon when using assets_path setting - Fix invalid path to blocked.gif when using assets_path setting (#6752) diff --git a/program/lib/Roundcube/rcube_imap.php b/program/lib/Roundcube/rcube_imap.php index e5ac6e274..3b408e99c 100644 --- a/program/lib/Roundcube/rcube_imap.php +++ b/program/lib/Roundcube/rcube_imap.php @@ -2406,13 +2406,15 @@ class rcube_imap extends rcube_storage $part_data = rcube_imap_generic::getStructurePartData($structure, $part); $o_part = new rcube_message_part; - $o_part->ctype_primary = $part_data['type']; - $o_part->encoding = $part_data['encoding']; - $o_part->charset = $part_data['charset']; - $o_part->size = $part_data['size']; + $o_part->ctype_primary = $part_data['type']; + $o_part->ctype_secondary = $part_data['subtype']; + $o_part->encoding = $part_data['encoding']; + $o_part->charset = $part_data['charset']; + $o_part->size = $part_data['size']; } - if ($o_part && $o_part->size) { + // Note: multipart/* parts will have size=0, we don't want to ignore them + if ($o_part && ($o_part->size || $o_part->ctype_primary == 'multipart')) { $formatted = $formatted && $o_part->ctype_primary == 'text'; $body = $this->conn->handlePartBody($this->folder, $uid, true, $part ? $part : 'TEXT', $o_part->encoding, $print, $fp, $formatted, $max_bytes); diff --git a/program/lib/Roundcube/rcube_imap_generic.php b/program/lib/Roundcube/rcube_imap_generic.php index 3fe3f7b62..5ff525407 100644 --- a/program/lib/Roundcube/rcube_imap_generic.php +++ b/program/lib/Roundcube/rcube_imap_generic.php @@ -3634,6 +3634,7 @@ class rcube_imap_generic } else { $data['type'] = strtolower($part_a[0]); + $data['subtype'] = strtolower($part_a[1]); $data['encoding'] = strtolower($part_a[5]); // charset