doc:appunti:prog:esempi_maildrop
This is an old revision of the document!
Esempio regole maildrop
# regex flags, used after the regex: /something/:b # :h - header # :b - body # :D - distinguish between upper and lower case (default is to ignore case) MAILDIRMAKE="/usr/bin/maildirmake" # configure for mbox, maildir, or mh TYPE="maildir" logfile "$HOME/mailfilter.log" DEFAULT="$HOME/Maildir" #------------------------------------------------------------------------- # Filter the mail with ClamAV #------------------------------------------------------------------------- exception { xfilter "/usr/bin/sanitizer /etc/sanitizer.cfg" } #------------------------------------------------------------------------- # Filter the mail with SpamAssassin # spamc automatically skip messages greater than 512000 bytes. #------------------------------------------------------------------------- if ( $SIZE < 256000 ) { exception { xfilter "/usr/bin/spamc" } } #------------------------------------------------------------------------- # Blackhole or move into subfolder messages tagged as SPAM. #------------------------------------------------------------------------- if ( /^X-Spam-Flag: *YES/ ) { exception { #to "/dev/null" # Create Spam subfolder (little overhead if it exists). #`${MAILDIRMAKE} -f Spam "$DEFAULT"` to "$HOME/Maildir/.Spam/" } }
doc/appunti/prog/esempi_maildrop.1392715121.txt.gz · Last modified: 2014/02/18 10:18 by niccolo