Results 1 to 1 of 1

Thread: Z-Push IMAPBackend BUG and possible patch

  1. #1
    Junior Member
    Join Date
    Dec 2015
    Posts
    1

    Z-Push IMAPBackend BUG and possible patch

    Hello,

    I don't know if this is the right place for this, but I didn't find another place (on z-push.org or some on-line contributing tools like github).

    I have trouble sending s/mime encoded emails with the z-push (2.2.7 stable) ImapBackend. The problem is located in the body mime encoding handling (which seems incomplete). The problem is s/mime encoded emails are always send without body. If you set logging to DEBUG you can see the problem in the log file:
    "BackendIMAP->SendMail(): parsed message" show an object with raw base64 body followed by the line "BackendIMAP->SendMail(): body: " where no body is present.
    Tracing the problem in the source file backend/imap/imap.php leads to the function getBody (line 1578) and function getBodyRecursive (line 1602). There is only mime handling for text/html emails with mime text and multipart implemented.

    s/mime data looks like this:

    Possible solution for s/mime:


    Insert this at the end of the getBodyRecursive function (line 1613) (patchfile):
    Full new method:
    This may not be a perfect solution since it does not do a good/complete mime interpretation. On the other side the implementation of body mime checking seems incomplete anyhow. May be it would be a better approach to implement smtp and connect to the real smtp server instead of trying to parse the mail. This causes less trouble and would avoid having bad mail headers like "Return-Path: <[email protected]>" but give the real senders name. I really recommend using such a solution. Feedback to this Idea appreciated.

    Best, hc42
    Last edited by hc42; 11-12-2015 at 09:44 PM.

Similar Threads

  1. Patch for autodiscover (by @JoshData), don't use
    By fmbiete in forum Z-Push when using Kopano/Zarafa
    Replies: 1
    Last Post: 27-08-2014, 05:12 PM
  2. Z-push patch to solve undeleted messages problem with low connectity
    By massimo in forum Z-Push when using Kopano/Zarafa
    Replies: 0
    Last Post: 26-02-2014, 10:14 AM
  3. Z-Push UAC Patch f. 2.0
    By Banks in forum Z-Push when using Kopano/Zarafa
    Replies: 2
    Last Post: 16-11-2012, 12:11 PM
  4. [patch] to include/exclude folders in z-push for privacy
    By joergschne in forum Z-Push when using Kopano/Zarafa
    Replies: 1
    Last Post: 12-05-2011, 03:37 PM
  5. [patch] Z-Push including trunk does not remove phone numbers
    By sbingner in forum Mobile devices Archives
    Replies: 1
    Last Post: 29-03-2011, 07:27 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •