Page 1 of 7

8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Thu Jun 13, 2019 11:57 pm
by joho
The patch announced here: https://blog.zimbra.com/2019/06/new-zim ... -patch-12/

And with a changelog here: https://wiki.zimbra.com/wiki/Zimbra_Releases/8.8.12/P3

Will break signatures with inline images, but not quite like Zimbra puts it ("Inline attachment shows as an attachment in compose window.")

What's worse is that *every time* the message is saved to Drafts, the inline image in the signature is added, again, as an attachment. If you have 30-60 seconds between auto-save-drafts, you can easily end up with 5-15 attachments, depending on how fast you type and how much you type. This error is quite easy to reproduce by simply clicking the "Save draft" button.

We've reported this to Zimbra. The response so far isn't overwhelming. :?


-joho

Re: 8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Fri Jun 14, 2019 1:13 am
by gbkersey
Amazing... I don't think they had time to test the patch to mbox war..... from the git log:

commit 302b9ec9d99004670e046af58919635618cbf739 (HEAD -> develop, origin/develop, origin/HEAD)
Author: Aumin Patel <auminpatel007@gmail.com>
Date: Tue Jun 11 14:55:01 2019 +0530

ZBUG-7209 : decoding the cid of inline images for owasp feature

commit a0a68883536d3baf0cb64fcea2f3d061a33218ec
Author: Aumin Patel <auminpatel007@gmail.com>
Date: Mon Jun 10 18:03:10 2019 +0530

ZBUG-7209 : adding html-decoder for inline images for owasp feature to decode the @ character

My date math is a bit suspect, but how many hours is it betewwn 3PM India time and noon Central Daylight time in the US??? Not very long...

Anyway, the fix that worked for me (so far) is just to revert the zimbra-mbox-war package to to the original version shipped with 8.8.12 - zimbra-mbox-war_8.8.12.1553847719 - then - su - zimbra -c "zmmailboxdctl restart"

I guess Quality Control is a thing of the past.

Re: 8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Fri Jun 14, 2019 6:33 am
by joho
gbkersey wrote:Amazing... I don't think they had time to test the patch to mbox war..... from the git log ...

Anyway, the fix that worked for me (so far) is just to revert the zimbra-mbox-war package to to the original version shipped with 8.8.12 - zimbra-mbox-war_8.8.12.1553847719 - then - su - zimbra -c "zmmailboxdctl restart"

I guess Quality Control is a thing of the past.

Thanks.

<sigh> ... I just reverted ours and it's still showing the same issue(s). It can be easily checked for by just clicking the "Save draft" button, at which point the inline signature image is added as an attachment again, and again, and ...

This is ridiculous, and not the first time :roll:


-joho

Re: 8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Fri Jun 14, 2019 7:11 am
by zimbraLuis
Hello,

I have the same problem with new patch 12 in version 8.7.11

Do you have any issue for fix that ?

Thanks,
Luis

Re: 8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Fri Jun 14, 2019 7:18 am
by joho
zimbraLuis wrote:I have the same problem with new patch 12 in version 8.7.11
Do you have any issue for fix that ?

This is probably caused by the same malfunctioning code. I'm afraid I don't know how to fix this in either version.

-joho

Re: 8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Fri Jun 14, 2019 7:54 am
by Inglebard
Hi,

This fix https://github.com/Zimbra/zm-web-client/pull/490 was publish the same day of the zimbra patch.
It doesn't seems to be included in it and seems to fix the issue.

At least, it works for me.

Re: 8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Fri Jun 14, 2019 9:01 am
by zimbraLuis
Inglebard wrote:Hi,

This fix https://github.com/Zimbra/zm-web-client/pull/490 was publish the same day of the zimbra patch.
It doesn't seems to be included in it and seems to fix the issue.

At least, it works for me.


The issue is fix in version 8.8.12 or 8.7.11 ?

Regards,
Luis

Re: 8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Fri Jun 14, 2019 9:37 am
by scantec
Same here. Amazing how this isn't even tested.. but at the same time not a surprise when you already know how Zimbra team prioritize issues

Re: 8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Fri Jun 14, 2019 10:32 am
by scantec
Didn't work in my case 8.8.12 + patch 3
Inglebard wrote:Hi,

This fix https://github.com/Zimbra/zm-web-client/pull/490 was publish the same day of the zimbra patch.
It doesn't seems to be included in it and seems to fix the issue.

At least, it works for me.

Re: 8.8.12 Patch 3 breaks inline signatures and creates multiple attachments

Posted: Fri Jun 14, 2019 3:15 pm
by Inglebard

Code: Select all

ZmMailMsg.prototype.findAttsFoundInMsgBody =
function() {
   if (this.findAttsFoundInMsgBodyDone) { return; }
   var content = "", cid;
   var bodyParts = this.getBodyParts();
   for (var i = 0; i < bodyParts.length; i++) {
      var bodyPart = bodyParts[i];
      if (bodyPart.contentType == ZmMimeTable.TEXT_HTML) {
         content = bodyPart.getContent();
         var msgRef = this;
         content.replace(/src=([\x27\x22])cid:([^\x27\x22]+)\1/ig, function(s, q, cid) {
            cid=cid.replace(/&#64;/g, "@");
            var attach = msgRef.findInlineAtt("<" + AjxStringUtil.urlComponentDecode(cid)  + ">");
            if (attach) {
               attach.foundInMsgBody = true;
            }
         });
      }
   }
   this.findAttsFoundInMsgBodyDone = true;
};


Maybe this ?

Edit : I manually change the cid line from the the PR 490.