Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/roundcube/roundcubemail.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2022-03-13 19:11:43 +0300
committerAleksander Machniak <alec@alec.pl>2022-03-13 19:11:43 +0300
commit13e863e22350235e7d78e31664b6158f3f538760 (patch)
tree4680e409b80ba378fb5b09c9fa594614fef09f2a /plugins
parent18f1a33fccbbe3edd8750bc1b71257eb3519c2c3 (diff)
Enigma: Fix double quoted-printable encoding of pgp-signed messages with no attachments (#8413)
Diffstat (limited to 'plugins')
-rw-r--r--plugins/enigma/lib/enigma_mime_message.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/plugins/enigma/lib/enigma_mime_message.php b/plugins/enigma/lib/enigma_mime_message.php
index c38153b91..4905a780b 100644
--- a/plugins/enigma/lib/enigma_mime_message.php
+++ b/plugins/enigma/lib/enigma_mime_message.php
@@ -189,10 +189,14 @@ class enigma_mime_message extends Mail_mime
$headers = $this->message->headers();
$params = ['content_type' => $headers['Content-Type']];
- if ($headers['Content-Transfer-Encoding']
+ if (!empty($headers['Content-Transfer-Encoding'])
&& stripos($headers['Content-Type'], 'multipart') === false
) {
$params['encoding'] = $headers['Content-Transfer-Encoding'];
+
+ // For plain text body we have to decode it back, to prevent from
+ // a double encoding issue (#8413)
+ $this->body = rcube_mime::decode($this->body, $this->build_params['text_encoding']);
}
$message->addSubpart($this->body, $params);