back to phpList.org

DKIM b= signature field is empty

I’ve configured in PHPMailer.php the DKIM variables ($DKIM_selector, $DKIM_identity, and so on …)

I get a dkim email as follows

DKIM-Signature: v=1; d=mydom.com; s=dkimsel;
a=rsa-sha256; q=dns/txt; l=30; t=1573568421; c=relaxed/simple;
h=Date:To:From:Subject:Message-ID:Content-Type;
i=sender@mydom.com;
bh=qw8RdF6sfjj2XXXXXXXXYYYYYYJ5C5mav6ijQn4kYgctWY=;
b=

and the signature field is empty.

My DKIM configuration is OK. I can send without problems with other software dkim-signed emails.

phplist in v3.4.8 with ‘phpmailer 6’ or v3.4.7 with ‘phpmailer 5’ behaves in similar way.
I thought the new version has not the same problem.

What is wrong with the config?

It looks as if the PHPMailer method DKIM_Sign is returning an empty string. Either openssl is not installed or the signing by openssl_sign() is failing.

The php-module openssl is installed, using php 7.2.

I inserted the PEM-formated string in var $DKIM_private_string of PHPMailer.php. No CRLF only one long string. The variable $DKIM_private stays empty.

Probably something is not correct?

@massi there is an example of how to use DKIM in the phpmailer repository. Perhaps you can try to get that working, as it then rules out phplist. See https://github.com/PHPMailer/PHPMailer/tree/master/examples