Improve get-token reliability
authorClinton Ebadi <clinton@unknownlamer.org>
Tue, 19 May 2015 06:21:26 +0000 (02:21 -0400)
committerClinton Ebadi <clinton@unknownlamer.org>
Tue, 19 May 2015 06:21:26 +0000 (02:21 -0400)
commitebec2a0b048ff83934b06f4324496b11173954a3
tree1f9790674ea07eb1e85b615dcb88d9419c24b9dd
parent6ca3e37a5f30904b430ce9073831275f6e543e16
Improve get-token reliability

On modern systems, there are issues with get-token calling itself when
invoked as root. Update routers to normalize where get-token is called
so that it is always called after seteuid() in the delivery process.

This is still not ideal: exim has to run without a PAG, and there's no
guarantee the directory / environment options will be run after
changing to the delivery user in the future.

Add `check_owner = false' to appendfile routers. We have patched exim
to support delivery into afs because it is overly paranoid about
chown() failures. Patch uses check_owner flag to allow chown() failure
since exim will ignore the owner in other cases anyway when it is
enabled.

Move tokens stashes to /var/local/mail-tokens rather than storing in
/tmp.

Leave some extra debugging in get-token for now.
conf.d/transport/30_exim4-config_maildir_home
conf.d/transport/35_exim4-config_address_directory
conf.d/transport/40_exim4-config_virtual_delivery
get-token