Encrypt copy of outgoing mail
This commit is contained in:
parent
7aa81a0b29
commit
89ebbbce4b
|
@ -4004,24 +4004,18 @@ function encrypt_outgoing_email {
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo 'sent_items_router:' > /etc/exim4/conf.d/router/170_exim4-config_encryptsent
|
if [ ! -d /home/$MY_USERNAME/.gnupg ]; then
|
||||||
echo ' driver = accept' >> /etc/exim4/conf.d/router/170_exim4-config_encryptsent
|
return
|
||||||
echo ' transport = sent_items_transport' >> /etc/exim4/conf.d/router/170_exim4-config_encryptsent
|
fi
|
||||||
echo ' condition = ${if !eq{$authenticated_id}{}}' >> /etc/exim4/conf.d/router/170_exim4-config_encryptsent
|
|
||||||
echo ' unseen' >> /etc/exim4/conf.d/router/170_exim4-config_encryptsent
|
|
||||||
echo ' no_verify' >> /etc/exim4/conf.d/router/170_exim4-config_encryptsent
|
|
||||||
|
|
||||||
# TODO
|
if [ ! $MY_GPG_PUBLIC_KEY_ID ]; then
|
||||||
echo 'sent_items_transport:'
|
MY_GPG_PUBLIC_KEY_ID=$(su -c "gpg --list-keys $MY_EMAIL_ADDRESS | grep 'pub '" - $MY_USERNAME | awk -F ' ' '{print $2}' | awk -F '/' '{print $2}')
|
||||||
echo ' driver = pipe'
|
if [ ! $MY_GPG_PUBLIC_KEY_ID ]; then
|
||||||
echo ' user = $authenticated_id'
|
return
|
||||||
echo ' group = Debian-exim'
|
fi
|
||||||
echo ' temp_errors = *'
|
fi
|
||||||
echo ' transport_filter = /usr/bin/gpgit.pl $sender_address'
|
|
||||||
echo ' command = /usr/bin/pipe2imap.pl --ssl --user master --authas $authenticated_id --passfile /etc/exim4/master_imap_password.txt --folder "Sent Items" --flags "\\seen"'
|
|
||||||
echo ' log_defer_output = true'
|
|
||||||
|
|
||||||
service exim4 restart
|
sed -i "s|#encrypt-to .*|hidden-encrypt-to $MY_GPG_PUBLIC_KEY_ID|g" /home/$MY_USERNAME/.gnupg/gpg.conf
|
||||||
|
|
||||||
echo 'encrypt_outgoing_email' >> $COMPLETION_FILE
|
echo 'encrypt_outgoing_email' >> $COMPLETION_FILE
|
||||||
}
|
}
|
||||||
|
@ -7046,7 +7040,7 @@ create_procmail
|
||||||
configure_imap
|
configure_imap
|
||||||
configure_gpg
|
configure_gpg
|
||||||
encrypt_incoming_email
|
encrypt_incoming_email
|
||||||
#encrypt_outgoing_email
|
encrypt_outgoing_email
|
||||||
email_client
|
email_client
|
||||||
configure_firewall_for_email
|
configure_firewall_for_email
|
||||||
folders_for_mailing_lists
|
folders_for_mailing_lists
|
||||||
|
|
Loading…
Reference in New Issue