doc:appunti:linux:sa:sieve_filtering_tnef
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
doc:appunti:linux:sa:sieve_filtering_tnef [2021/05/24 12:40] – [The Sieve filter] niccolo | doc:appunti:linux:sa:sieve_filtering_tnef [2021/05/24 13:01] – [The Sieve filter] niccolo | ||
---|---|---|---|
Line 6: | Line 6: | ||
The original TNEF attachment is retained, so **the size of the email is roughly doubled**. | The original TNEF attachment is retained, so **the size of the email is roughly doubled**. | ||
+ | |||
+ | ===== Reference installation ===== | ||
+ | |||
+ | I'm running a mail server based on **Debian 10 Buster**, the IMAP, POP3 and LDA services are provided by **Dovecot**. The Local Delivery Agent have the **Sieve** filtering enabled. You can read the configuration details in this article: **[[postfix_spamassassin_clamav_dovecot# | ||
+ | |||
+ | ===== Installing the tnef-filter script ===== | ||
+ | |||
+ | First of all we need a mail filter program which does all the magic. It will receive the mail message as standard input and it will produce the // | ||
+ | |||
+ | You can download the **tnef-filter** script written by **Graham Edgecombe**, | ||
+ | |||
+ | Running the script on my Debian 10 Buster server, requied the following libraries: | ||
+ | |||
+ | < | ||
+ | apt-get install libconvert-tnef-perl libfile-mmagic-perl libmime-tools-perl | ||
+ | </ | ||
===== The Sieve filter ===== | ===== The Sieve filter ===== | ||
+ | |||
+ | In my installation, | ||
< | < | ||
Line 23: | Line 41: | ||
</ | </ | ||
- | You need to include the **mime** and **foreverypart** plugins. | + | Notice that you need to include the **mime** and **foreverypart** plugins. |
- | I created the shell script **tnef-filter.sh** into the **/ | + | I created the shell script **tnef-filter.sh** into the **/ |
+ | |||
+ | <code bash> | ||
+ | #!/bin/sh | ||
+ | / | ||
+ | </ | ||
+ | |||
+ | The directory is the one declared to contains Sieve filters. You can set that location into **/ | ||
< | < | ||
Line 32: | Line 57: | ||
} | } | ||
</ | </ | ||
+ | |||
doc/appunti/linux/sa/sieve_filtering_tnef.txt · Last modified: 2021/05/24 13:03 by niccolo