# Sample procmail recipe to invoke crm114's mailfilter from # inside procmail. Use this as a last-ditch filter after your # previous blacklists, whitelists, etc. #xs # This code written by Craig Hagan. # # NOTE: since you probably aren't named "Craig Hagan", you will need # to edit the filenames below to suit. You will also need to set the # procmail mode in mailfilterconfig.cf # :0fw: .msgid.lock | /home/hagan/crm/crm114 -u /home/hagan/crm mailfilter.crm :0: * ^X-CRM114-Status: SPAM.* mail/crm-spam # OPTIONAL CODE OPTIONAL CODE OPTIONAL CODE # # Some versions of procmail have a bug in them where they delete # the leading "F" from the "From" line. This missing "F" can really # confuse some mail reading software packages. If this screws up your # mailbox, insert this code up above as the first non-commented # procmail commands. # ## repair damaged "From", recover data ## adapted from http://www.metahusky.net/~gavin/viewer.html?procmail.\txt :0 H * ! ^From[ ] * ^rom[ ] { LOG="***--->>> repaired missing F on [F]rom_ in header <<<---***" :0 fhw | sed -e '1s/^rom /From /' }