We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi!
Today I upgraded from version 6.0.1 to 6.6.3 of PHPMailer. This corrected some previous issues, but there is a new one. The case:
isMail()
This results an invalid DKIM-signature.
What happens is the following:
preSend()
undisclosed-recipients:;
$this->mailHeader
z
mailSend()
$to
This results in the following example headers (with invalid DKIM-signature):
Received: by mailserver (Postfix, from userid 33) id C53F3520B8D; Sat, 20 Aug 2022 14:00:55 +0000 (UTC) To: Subject: Testmail [...] DKIM-Signature: v=1; [...] h=Date:From:Reply-To:Message-ID:X-Mailer:MIME-Version:Content-Type:To:Subject; z=Date:Sat,=2020=20Aug=202022=2016:00:55=20+0200 |[...]To:undisclosed-recipients:=3B |Subject:Testmail;[...]
I was able to correct the behaviour by adding the following line after line 1894 in mailSend(): if($to == "") $to = "undisclosed-recipients:;";
if($to == "") $to = "undisclosed-recipients:;";
This results in the following example headers (with valid DKIM-signature):
Received: by mailserver (Postfix, from userid 33) id CE9AE520036; Sun, 21 Aug 2022 08:45:47 +0000 (UTC) To: undisclosed-recipients:; Subject: Testmail [...] DKIM-Signature: v=1; [...] h=Date:From:Reply-To:Message-ID:X-Mailer:MIME-Version:Content-Type:To:Subject; z=Date:Sun,=2021=20Aug=202022=2010:45:47=20+0200 |[...]|To:undisclosed-recipients:=3B |Subject:Testmail;[...]
The text was updated successfully, but these errors were encountered:
Good catch. Could you please wrap that up in a PR?
Sorry, something went wrong.
Review-ready :) See PR #2754
No branches or pull requests
Hi!
Today I upgraded from version 6.0.1 to 6.6.3 of PHPMailer. This corrected some previous issues, but there is a new one.
The case:
isMail()
This results an invalid DKIM-signature.
What happens is the following:
preSend()
line 1607 the To-addresseeundisclosed-recipients:;
is added to the headers in$this->mailHeader
z
-field)mailSend()
the variable$to
will be empty since there are no To-addressees and the email will be sent as suchThis results in the following example headers (with invalid DKIM-signature):
I was able to correct the behaviour by adding the following line after line 1894 in
mailSend()
:if($to == "") $to = "undisclosed-recipients:;";
This results in the following example headers (with valid DKIM-signature):
The text was updated successfully, but these errors were encountered: