Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-4502

Invalid Return-Path results in failed reply forwarding

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Critical
    • Resolution: Fixed/Completed
    • Affects Version/s: 2.2.2
    • Fix Version/s: 3.0
    • Component/s: CiviMail
    • Labels:
      None

      Description

      In CRM_Mailing_Event_BAO_Reply::send(), the Return-Path header may have invalid formatting. Specifically, I encountered the form "<person@domain.com>". Certain MTAs with certain configuration (including Exim in this particular case) reject this header and refuse to send the mailing.

      My quick fix was to add the following:
      $b = $parsed->generateBody();

      + // Fix bug where Return-Path has invalid format.
      + $h['Return-Path'] = trim($h['Return-Path'], '<>');

      // FIXME: ugly hack - find the first MIME boundary in
      // the body and make the boundary in the header match it

      I also noticed the return of $mailer->send() isn't being checked for errors. If it had been, this would have been much easier to catch.

        Attachments

          Activity

            People

            • Assignee:
              neha.saraph Neha Kulkarni
              Reporter:
              davidstrauss David Strauss
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: