6.0.0-beta1
7/6/25

[#14656] Corupted mail while reply/forward when original mail has s/mime signed and in html format
Summary Corupted mail while reply/forward when original mail has s/mime signed and in html format
Queue IMP
Queue Version 6.2.19
Type Bug
State Resolved
Priority 1. Low
Owners jan (at) horde (dot) org
Requester jiri.slezka (at) slu (dot) cz
Created 06/12/2017 (2946 days ago)
Due
Updated 10/20/2017 (2816 days ago)
Assigned 06/23/2017 (2935 days ago)
Resolved 06/26/2017 (2932 days ago)
Github Issue Link
Github Pull Request
Milestone 6.2.20
Patch No

History
10/20/2017 08:33:49 PM Git Commit Comment #8 Reply to this comment
Changes have been made in Git (FRAMEWORK_5_2):

commit a0b5738000e7a1db95d278872ba63439b09ffbdd
Author: Jan Schneider <jan@horde.org>
Date:   Mon, 26 Jun 2017 14:24:43 +0200

[jan] Fix finding reply or forward text from signed or encrypted 
messages with HTML content again (Bug #14656).

  M docs/CHANGES
  M package.xml

https://github.com/horde/imp/commit/a0b5738000e7a1db95d278872ba63439b09ffbdd
10/20/2017 08:33:48 PM Git Commit Comment #7 Reply to this comment
Changes have been made in Git (FRAMEWORK_5_2):

commit e04f3e2fa62fc0b09f6a98135f38c8548c3572be
Author: Jan Schneider <jan@horde.org>
Date:   Mon, 26 Jun 2017 14:22:24 +0200

Revert "Fix finding message text from signed/encrypted messages."

No idea why this was necessery once an no longer is now. Reverting it 
fixes bug #14656.

This reverts commit 110e7e64c33e4db942d81f45eb9b6c187839305c.

  M lib/Compose.php

https://github.com/horde/imp/commit/e04f3e2fa62fc0b09f6a98135f38c8548c3572be
06/26/2017 12:25:08 PM Jan Schneider Assigned to Jan Schneider
State ⇒ Resolved
Milestone ⇒ 6.2.20
 
06/26/2017 12:24:57 PM Git Commit Comment #6 Reply to this comment
Changes have been made in Git (FRAMEWORK_5_2):

commit 5869a755a6bbea75a28665a22fc13e47d1f212f8
Author: Jan Schneider <jan@horde.org>
Date:   Mon Jun 26 14:24:43 2017 +0200

     [jan] Fix finding reply or forward text from signed or encrypted 
messages with HTML content again (Bug #14656).

  imp/docs/CHANGES | 2 ++
  imp/package.xml  | 2 ++
  2 files changed, 4 insertions(+)

http://github.com/horde/horde/commit/5869a755a6bbea75a28665a22fc13e47d1f212f8
06/26/2017 12:24:57 PM Git Commit Comment #5 Reply to this comment
Changes have been made in Git (FRAMEWORK_5_2):

commit ae6a6d7664e59ad69c69442325600edadfbba5e6
Author: Jan Schneider <jan@horde.org>
Date:   Mon Jun 26 14:18:07 2017 +0200

     Revert "Fix finding message text from signed/encrypted messages."

     No idea why this was necessery once an no longer is now. 
Reverting it fixes bug #14656.

     This reverts commit 110e7e64c33e4db942d81f45eb9b6c187839305c.

  imp/lib/Compose.php | 6 ------
  1 file changed, 6 deletions(-)

http://github.com/horde/horde/commit/ae6a6d7664e59ad69c69442325600edadfbba5e6
06/26/2017 12:08:31 PM Jan Schneider Comment #4 Reply to this comment
According to git bisect, this commit is the culprit, that was actually 
supposed to fix exactly that issue: 
https://github.com/horde/horde/commit/110e7e64c33e4db942d81f45eb9b6c187839305c
06/23/2017 01:29:37 PM Jan Schneider Comment #3
Priority ⇒ 1. Low
State ⇒ Feedback
Taken from Horde DevelopersHorde Developers
Reply to this comment
FWIW this doesn't happen in master. If someone finds out what fixed it 
there, we may backport this to the stable version. Otherwise we 
probably won't spend time on fixing this there.
06/22/2017 01:11:27 PM Jan Schneider Comment #2
Assigned to Horde DevelopersHorde Developers
State ⇒ Assigned
Reply to this comment
Confirmed
06/12/2017 02:17:45 PM jiri (dot) slezka (at) slu (dot) cz Comment #1
Priority ⇒ 2. Medium
State ⇒ Unconfirmed
New Attachment: forwarding.png Download
Patch ⇒ No
Milestone ⇒
Queue ⇒ IMP
Summary ⇒ Corupted mail while reply/forward when original mail has s/mime signed and in html format
Type ⇒ Bug
Reply to this comment
Hello,

if you receive mail that is s/mime signed and in html format and you 
try to reply or forward it in html format, its content is corrupted 
(see attached screenshot - in the red rectangle).

The original mail has to be s/mime signed and in html format. The 
signed mail is commonly cresated in Thunderbird or MS Outlook. When it 
is signed and in plaintext or it is unsigned and in html Imp works 
fine. Also when you uncheck the "compose in html" checkbox all is 
working fine.

I believe it could be problem in parsing of multipart message. Part of 
headers of original mail follows

...
Content-Type: multipart/signed; protocol="application/pkcs7-signature";
micalg=sha-256; boundary="------------ms070302060509050603000208"

This is a cryptographically signed message in MIME format.

--------------ms070302060509050603000208
Content-Type: multipart/alternative;
  boundary="------------BCBB714262F81EB40298387E"
Content-Language: Cestina

This is a multi-part message in MIME format.
--------------BCBB714262F81EB40298387E
Content-Type: text/plain; charset=iso-8859-2; format=flowed
Content-Transfer-Encoding: quoted-printable

plaintext text


--------------BCBB714262F81EB40298387E
Content-Type: text/html; charset=iso-8859-2
Content-Transfer-Encoding: quoted-printable

<html>
html text
</html>

--------------BCBB714262F81EB40298387E--

--------------ms070302060509050603000208
Content-Type: application/pkcs7-signature; name="smime.p7s"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="smime.p7s"
Content-Description: Elektronicky podpis S/MIME

MIAGCSqGSIb3DQEHAqC....
...

The corrupted characters are utf-8 representation of smime.p7s bytes.

Saved Queries