<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252">
</head>
<body>
<div class="moz-cite-prefix">On 12-10-2020 10:16, Robert Martin
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:119d01d6a06f$f25e2b00$d71a8100$@insol6.com">
<meta name="Generator" content="Microsoft Word 15 (filtered
medium)">
<div class="WordSection1">
<p class="MsoNormal">I created a client library to send emails
for a webapp.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">After connecting to the SMTP server with
credential setup in CPANEL, and then do NOT add Message-Id
header, the DKIM signature 'h' record created by dovecot/WHM
is wrong, and a Message-ID (with a capital D) header is added,
invalidating the generated DKIM signature value.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">This causes outlook, yahoo, gmail and other
email recipients to add 'dkim:fail' to the message, and thus
relegate it to junk or spam.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">The work around is to add to the message a
Message-Id with a little ‘d’ header. Then the SMTP server
processes the email with the correct generated DKIM, correct
DKIM ‘h’ record and does not add a Message-ID header.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">My SMTP hosting providers that run the
WHM/dovecot/CPANEL software are refusing to raise this as a
bug and have requested that I do it.</p>
</div>
</blockquote>
<p>Hi Robert,</p>
<p>Dovecot does not add DKIM headers, Dovecot doesn't even send
email. Aside from that:</p>
<p>- The RFC states that "Message-ID" is the actual spelling:
<a class="moz-txt-link-freetext" href="https://tools.ietf.org/html/rfc5322#section-3.6.4">https://tools.ietf.org/html/rfc5322#section-3.6.4</a></p>
<p>- The DKIM signer implementation in CPANEL/WHM seems to do the
right thing: It adds a Message-ID header if it's missing, and
creates a DKIM signature. It seems unlikely that the CPANEL/WHM
DKIM implementation generates invalid DKIM signatures for all
Message-ID headers it generates, as lots of people would have
issues with that.<br>
</p>
<p>It's unclear from your inital message what's wrong with the
generated DKIM signature, and it's also unclear where the
"Message-Id" header (with lowercase 'd') comes from. Could you
please explain? Can you show full headers for a message with the
broken DKIM and all the relevant headers?<br>
</p>
Kind regards,
<p>Tom<br>
</p>
</body>
</html>