How To Automatically Add A Disclaimer To Outgoing Emails With alterMIME (Postfix On Debian Etch)
How To Automatically Add A Disclaimer To Outgoing Emails With alterMIME (Postfix On Debian Etch)Version 1.0 This tutorial shows how to install and use alterMIME. alterMIME is a tool that can automatically add a disclaimer to emails. In this article I will explain how to install it as a Postfix filter on Debian Etch. I do not issue any guarantee that this will work for you!
1 Preliminary NoteI'm assuming that Postfix is already installed and fully functional - I will not explain how to set up Postfix and configure email accounts in this tutorial.
2 Installing alterMIMEalterMIME can be installed as follows: apt-get install altermime Next we create the user filter with the home directory /var/spool/filter filter - alterMIME will be run as that user: useradd -r -c "Postfix Filters" -d /var/spool/filter filter Afterwards we create the script /etc/postfix/disclaimer which executes alterMIME. Debian's alterMIME package comes with a sample script that we can simply copy to /etc/postfix/disclaimer: cp /usr/share/doc/altermime/examples/postfix_filter.sh /etc/postfix/disclaimer Now the problem with this script is that it doesn't distinguish between incoming and outgoing emails - it simply adds a disclaimer to all mails. Typically you want disclaimers only for outgoing emails, and even then not for all sender addresses. Therefore I've modified the /etc/postfix/disclaimer script a little bit - we'll come to that in a minute. Right now, we create the file /etc/postfix/disclaimer_addresses which holds all sender email addresses (one per line) for which alterMIME should add a disclaimer: vi /etc/postfix/disclaimer_addresses
Now we open /etc/postfix/disclaimer and modify it as follows (I have marked the parts that I've changed): vi /etc/postfix/disclaimer
Next we need the text file /etc/postfix/disclaimer.txt which holds our disclaimer text. Debian's alterMIME package comes with a sample text that we can use for now (of course, you can modify it if you like): cp /usr/share/doc/altermime/examples/disclaimer.txt /etc/postfix/disclaimer.txt Finally we have to tell Postfix that it should use the /etc/postfix/disclaimer script to add disclaimers to outgoing emails. Open /etc/postfix/master.cf and add -o content_filter=dfilt: to the smtp line: vi /etc/postfix/master.cf
At the end of the same file, add the following two lines:
Restart Postfix afterwards: /etc/init.d/postfix restart That's it! Now a disclaimer should be added to outgoing emails sent from the addresses listed in /etc/postfix/disclaimer_addresses.
3 Links
|
www.seamlessenterprise.com
One number. One voicemail. Seize the lead. Sprint Mobile Integration.
www.seamlessenterprise.com
One Number. One Voicemail.
Make it easier for clients to reach you. Turn your desk phone and mobile phone into one with Sprint Mobile Integration.
www.seamlessenterprise.com
One number. One voicemail. Sprint Mobile Integration.
www.seamlessenterprise.com
AT&T Synaptic Compute as a Service. Boost your power on demand.
Trial: IBM Cognos Express Reporting, Analysis & Planning







Recent comments
13 hours 36 min ago
15 hours 37 min ago
18 hours 48 min ago
21 hours 7 min ago
22 hours 17 min ago
23 hours 36 min ago
1 day 3 hours ago
1 day 7 hours ago
1 day 7 hours ago
1 day 22 hours ago