I have configured Postfix to sign my mails using OpenDKIM. (I followed this tutorial.)
Now I would like to configure Postfix to reject mails for domains that have DKIM configured and the mail lacks a proper signature (eg. when my own domain is used as fake sender address).
In opendkim.conf I enabled verification (Mode sv
) and in Postfic main.conf I have
milter_protocol = 2
milter_default_action = accept
smtpd_milters = inet:localhost:12301
Im mail.log I found
Feb 24 19:25:10 myhost postfix/cleanup[20016]: 113623DC1119: message-id=<[email protected]>
Feb 24 19:25:10 myhost opendkim[1355]: 113623DC1119: [78.90.96.5] [78.90.96.5] not internal
Feb 24 19:25:10 myhost opendkim[1355]: 113623DC1119: not authenticated
Feb 24 19:25:10 myhost opendkim[1355]: 113623DC1119: no signature data
Feb 24 19:25:10 myhost postfix/qmgr[1791]: 113623DC1119: from=<[email protected]>, size=1981, nrcpt=1 (queue active)
So OpenDKIM seems to have noticed that this mail isn't valid, but it didn't get rejected.