Re: [exim] DKIM signing for multiple domains

Top Page
Delete this message
Reply to this message
Author: Odhiambo Washington
Date:  
To: andrew
CC: exim users
Subject: Re: [exim] DKIM signing for multiple domains
On Tue, 25 Sep 2018 at 13:26, Andrew Colin Kissa via Exim-users <
exim-users@???> wrote:

>
> > On 25 Sep 2018, at 09:28, Odhiambo Washington via Exim-users <
> exim-users@???> wrote:
> >
> > I have multiple domains hosted on the same server. They are virtual
> > domains. The server has just one IP address and one Exim instance.
> > I am wondering how to easily do DKIM signing for these domains. I decided
> > to use the same selector for all the domains to make life easy. Would the
> > following transport work? If not, what is the best way to do this for
> > multiple domains sharing the same IP address?
> >
> > remote_smtp_DK:
> > driver = smtp
> > dkim_domain = ${sender_address_domain}
> > dkim_selector = csl
> > dkim_private_key =
> > "/etc/pki/tls/dk/${sender_address_domain}-dkim.priv.key"
> > dkim_canon = relaxed
> > dkim_strict = true
>
> It is better to check for the existence of the key as follows.
>
> dkim_domain = ${if
> exists{/etc/pki/tls/dk/${lc:$sender_address_domain}-dkim.priv.key}{${lc:$sender_address_domain}}{}}
> dkim_private_key = ${if
> exists{/etc/pki/tls/dk/${lc:$sender_address_domain}-dkim.priv.key}\
>    {{/etc/pki/tls/dk/${lc:$sender_address_domain}-dkim.priv.key}{0}}

>
> - A
>
>

Thank you. However, for some reason this is generating an error:

2018-09-25 14:53:15 1g4jHp-000B76-VQ signing_init: error:0906D06C:PEM
routines:PEM_read_bio:no start line
2018-09-25 14:53:15 1g4jHp-000B76-VQ DKIM: signing failed: PRIVKEY
2018-09-25 14:53:15 1g4jHp-000B76-VQ DKIM: message could not be signed, and
dkim_strict is set. Deferring message delivery.

--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft."