James Server
  1. James Server
  2. JAMES-662

sendmail.py doesn't handle multiple TO-recipients

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 2.3.0
    • Fix Version/s: 2.3.1
    • Component/s: None
    • Labels:
      None
    • Environment:
      Debial Linux, Python 2.3.5, "Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64)"

      Description

      I got a problem with the sendmail.py-script from the /bin-directory:

      Wenn I try to send a mail to two TO-recipients from a PHP-Script, only
      the first one will be delivered

      <?PHP mail("stephan@one.de,stephan@two.de", "hallo", "moep", "From: stephan@three.de", "-fstephan@three.de"); ?>

      (yes, sendmail-option "-t" is set: phpinfo() -> "sendmail_path: /usr/sbin/sendmail -t")

      I'm no Python-guy, but this doesn't look like there's a extraction of multiple (comma-seperated) recipients:

      [...]
      if header.startswith("To:"):
      if extract:
      to = header[3:]
      to_addrs.append(to[("<" + to).rfind("<"):(to + ">").find(">")])
      [...]

        Activity

        Hide
        Danny Angus added a comment -

        Closing issue fixed in released version.

        Show
        Danny Angus added a comment - Closing issue fixed in released version.
        Hide
        Norman Maurer added a comment -

        I think this should be fixed in 2.3.1 too

        Show
        Norman Maurer added a comment - I think this should be fixed in 2.3.1 too
        Hide
        Stefano Bagnara added a comment -

        Assigning to Trunk so we don't forget this.

        Show
        Stefano Bagnara added a comment - Assigning to Trunk so we don't forget this.
        Hide
        Stephan Sann added a comment -

        Well, here you are. I modified the script to work with multiple recipients, too.

        Show
        Stephan Sann added a comment - Well, here you are. I modified the script to work with multiple recipients, too.
        Hide
        Noel J. Bergman added a comment -

        Correct. The code does not attempt to parse an address-list, just a single address, from the To: header. Contributions welcomed.

        Show
        Noel J. Bergman added a comment - Correct. The code does not attempt to parse an address-list, just a single address, from the To: header. Contributions welcomed.

          People

          • Assignee:
            Norman Maurer
            Reporter:
            Stephan Sann
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development