Mail forwarding with procmail

Mail forwarding with procmail

Post by John Potte » Mon, 26 Jul 1999 04:00:00



Hi

I was wondering if could tell me how I would go about writing a script that
forwards mail to another address.  This seems very simple except the fact
that I would like to use this script with procmail.

What I want to achieve in the end is something where procmail is used to
filter through incoming messages and depending on who is sending the message
different scripts are executed.  There is one script I would like so that
whenever a friend of mine emails me the subject header and date header are
forwarded to an email address to my cell phone.  I am NOT asking for advice
on using procmail, just wondering how I would get the information of the
headers in the shell script from procmail or if after procmail has processed
the incoming mail the information is stored in some kind of enviroment
variables or something that I can access in the script???  Or does anyone
know of any Perl modules that might be able to let me access this
information?  Although I would prefer just to write a shell script.

Sorry for the long-windedness of the question it's just that I didn't want
replies about how to use procmail.

I would appreciate it if you could send me any replies to

Thanks for your time and help.

Su

 
 
 

1. mail forward problem in RH71 with procmail or .forward

I edited ~/.forward as


Not working.

So I did some research...
Seems sendmail 8.11.6 with RH71 is using procmail not mail for local
delivery thing.  So it not reading .forward.

So I edited ~./procmailrc

:0c

still no forwarding.

I wondering if sendmail 8.11.6 on RH71 disabled forwarding for security
and spam reason?

I did the following too

# ln -s  /usr/bin/procmail /etc/smrsh

according to redhat faq

/ming

2. ROAST .RHOSTS

3. Forward Mail / Procmail

4. shutdown of SCO on Cpq Pro Signia

5. mail forwarding problem with ".forward" file

6. COMPAQ DESKPRO 6000

7. .forward file: possible to forward and also keep mail?

8. Need help with rm

9. Forwarding mail via .forward -- how to?

10. help! : procmail & .forward files

11. forward first N bytes w/procmail?

12. procmail: forwarding huge messages elsewhere

13. Forward and procmail