﻿id,summary,reporter,owner,description,type,status,priority,milestone,component,version,severity,resolution,keywords,cc
11988,VERP does not work,vladimir_kolesnikov,westi,"Suppose that we have a custom hook for ""phpmailer_init"" action which enables VERP support:

{{{
function phpmailer_init($phpmailer)
{
    $phpmailer->IsSMTP();
    if (!$phpmailer->smtp) {
        $phpmailer->smtp = new SMTP();
    }

    $phpmailer->smtp->do_verp = true;
}
}}}

But VERP support (in wp-includes/class-smtp.php) is a bit buggy: here's the transcript the session:

{{{
 Out: 220 example.com ESMTP Postfix
 In:  EHLO example.com
 Out: 250-example.com
 Out: 250-PIPELINING
 Out: 250-SIZE 10240000
 Out: 250-ETRN
 Out: 250-XVERP
 Out: 250-ENHANCEDSTATUSCODES
 Out: 250-8BITMIME
 Out: 250 DSN
 In:  MAIL FROM:<mailer@example.com>XVERP
 Out: 501 5.1.7 Bad sender address syntax
 In:  RSET
 Out: 250 2.0.0 Ok
}}}

You can see that the server (Postfix) supports VERP (250-XVERP) but the MAIL FROM line is malformed - it lacks space character between "">"" and ""XVERP"":

{{{
220 example.com ESMTP Postfix (Ubuntu)
EHLO example.com
250-example.com
250-PIPELINING
250-SIZE 10240000
250-ETRN
250-XVERP
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
MAIL FROM:<mailer@example.com> XVERP
250 2.1.0 Ok
RSET
250 2.0.0 Ok
QUIT
221 2.0.0 Bye
}}}

You can see that the space character solves the problem.
",defect (bug),closed,normal,,Mail,3.0,normal,invalid,has-patch,vladimir@… bpetty
