butternutsquash wrote:Hi,
I would say make sure you have the right privileges on your files and directories
-r-------- 1 amavis amavis 1675 Jun 24 15:27 /var/lib/dkim/yourdomain.com.pem
Also make sure /etc/amavis/conf.d/50-user is populated with the right info. See example below (replace yourdomain.com with your real domain name).
#
# DKIM
#
# Enable DKIM verification globally.
$enable_dkim_verification = 1;
# Disable DKIM signing globally, because it's controlled per policy bank.
#$enable_dkim_signing = 1;
# Add dkim_key here.
dkim_key('yourdomain.com', 'dkim', '/var/lib/dkim/yourdomain.com.pem');
@dkim_signature_options_bysender_maps = ({
# 'd' defaults to a domain of an author/sender address,
# 's' defaults to whatever selector is offered by a matching key
# Per-domain dkim key
"yourdomain.com" => { d => "yourdomain.com", a => 'rsa-sha256', ttl => 10*24*3600 },
# catch-all (one dkim key for all domains)
# '.' => {d => 'yourdomain.com',
# a => 'rsa-sha256',
# c => 'relaxed/simple',
# ttl => 30*24*3600 },
});
Ok so there actually isn't a file in that folder So I created one and gave it the correct permissions but I'm logged in as root anyway:
root@mail:/var/lib/dkim# touch cheesegoatemails.com.pem
root@mail:/var/lib/dkim# ls -a
. .. cheesegoatemails.com.pem .pem
root@mail:/var/lib/dkim# chmod 754 cheesegoatemails.com.pem
root@mail:/var/lib/dkim# ls -a
. .. cheesegoatemails.com.pem .pem
root@mail:/var/lib/dkim# amavisd-new showkeys
Error in config file "/etc/amavis/conf.d/50-user": dkim_key: domain must not be empty: (,dkim,/var/lib/dkim/cheesegoatemails.com.pem) at /usr/sbin/amavisd-new line 627.
Then the 50-user file, I did go through to the spot you suggested and combed through the file for other places and put my domain name in. However it still had the same error on reboot