procmail

What's in your .procmailrc

Are there any handy general items you put in your .procmailrc file? ...

procmail lockfile utility and NFS

G'day, Has anyone used the lockfile utility that ships with procmail in conjunction with NFS mounted directories? The lockfile man page states that "Lockfile is NFS-resistant and eight-bit clean." cheers, Rob ...

Adding headers to mail coming via exim4

I've got a Debian Etch system running Exim4-daemon-heavy. The system is open to the internet, but the intention is that it will only receive legitimate mail coming from a spam-filtering service, which runs as a proxy ahead of it. (I can't just limit access to those IPs though, because I do have some authorized users who relay via my se...

Procmail Troubles

I've been trying to solve this for weeks... My Goal is to search my inbox for the following messages: Hello Hi Hey Im using three files to do this for me. The first, a .forward file in my $HOME "|IFS=' '&&exec usr/bin/procmail||exit 75 #username" And these two are in my ~/.procmail directory .procmailrc VERBOSE=off MAILDIR=$HOME...

Procmail Forward script to forward emails from one domain to the other

I am trying to write a procmail forward script, which will forward all the mails received at mydomain.com to mydomain.NET. To be more clear, if mail is to:[email protected], it should forward to: [email protected]. Like this it should forward for all corresponding emails: How Can I do this? ...

How to receive all emails pertaining to a domain, on my production machine?

I have a strange requirement, any website user(not linux system user) will be getting a email id, say [email protected],[email protected] with which they are going to have a inbox feature built into their dashboard. Any outside user(can be anyone on the planet/not precisely my website user) can email this [email protected] and jack r...

Want procmail to run a custom python script, everytime a new mail shows up

I have a pretty usual requirement with procmail but I am unable to get the results somehow. I have procmailrc file with this content: :0 * ^To.*@myhost | /usr/bin/python /work/scripts/privilege_emails_forward.py Wherein my custom python script(privilege_emails_forward.py) will be scanning through the email currently received and do so...

Moving IMAP mail to Gmail and retaining correct times

I am trying to use gmail to manage mail from an email account I have that is imap only. My strategy was to use (getmail to retrieve mail from the server and pass it through to procmail for forwarding. This almost works. It successfully retrieves the mail and forwards it on to my gmail account. What it does not do it keep the appropr...

How can I send an automated reply to the sender and all recipients with Procmail?

I'd like to create a procmail recipe or Perl or shell script that will send an auto response to the original sender as well as anybody that was copied (either To: or cc:) on the original email. Example: [email protected] writes an email to [email protected] and [email protected] (in the To: field). Copies are sent via cc: to [email protected]...

How to determine which pattern in a file matched with grep?

I use procmail to do extensive sorting on my inbox. My next to last recipe matches the incoming From: to a (very) long white/gold list of historically good email addresses, and patterns of email addresses. The recipe is: # Anything on the goldlist goes straight to inbox :0 * ? formail -zxFrom: -zxReply-To | fgrep -i -f $HOME/Mail/gold...

How to append beginng of body to subject of mail (body of new mail can be erased) and forward it using e.g. procmail?

see the title for the question. that is all. ...

Procmailrc to process a catchall into folders

Hi all, Can anyone help me with a system wide procmailrc receipe? What I want to happen is that any email going to a special domain (catch all account) gets put in a local mailbox in a folder named the same as the username in the email address. Such that: [email protected] will be delivered to ...blahblahpath/foo/mail bar@special...

How to match any whitespace in body of mail in procmail?

I tried to use such rule: :0 B * Something[[:space:]]+whatever but it doesn't work. When I change [[:space:]] to literal space character: :0 B * Something +whatever it works. It also works in case of: :0 B * Something[ ]+whatever I must be doing something wrong, but can't really find it. Any hints? ...

Procmail vs. Maildrop - which to use?

I need to do mail processing where I manipulate the contents of the mail or invoke a script on the receipt of email, supporting a number of email addresses as the access points. In reading through the MDA agents, procmail appears to be the standard standby, but maildrop has some following too. Wikipedia comments that anyone starting some...

File Distribution via SMTP: How to do the receiving side?

Hi, I need to setup a file distribution system between different sites of a WAN. Files that are dropped into some input directories on the source machine should be distributed into a directory on each of the target machines at other sites. One of the requirements is that between certain sites the only allowed traffic is SMTP. There is a...

Move emails with procmail if it matches from sender

Hi, as im using different email clients to read/send my mails i want to setup procmail to move my emails to a the folder which is normally done by Thunderbird filter feature. I know that i can do it by using the following code for procmail in my email users .procmailrc file: :0: * ^From:[email protected] myfolder But i have a list...

I can't make procmail to process my mails

While this question sounds probably too general, there's not much I can say. I'm in a kind of hurry and can't browse like 666 pages of manuals, for procmail and stmp clients. What I've checked so far is that: manual execution of: procmail -m .procmailrc < /var/mail/mymails is working, but every time it processes the same mail. When I...