Beefy Boxes and Bandwidth Generously Provided by pair Networks httptech
Perl-Sensitive Sunglasses
 
PerlMonks  

What're some good ways of notifying a perl script of an incoming email?

( #165391=categorized question: print w/ replies, xml ) Need Help??
Contributed by ApoxyButt on May 09, 2002 at 14:57 UTC
Q&A  > mail and news


Description:

Assume I have access to the major email programs.

Answer: What're some good ways of notifying a perl script of an incoming email?
contributed by vagnerr

If you are Unix based, I would definatly recomend that you look at procmail. (man "procmail" or "procmailrc")

Answer: What're some good ways of notifying a perl script of an incoming email?
contributed by tye

The typical solution is to put | myPerlScript
in your .forward file. However, this feature is often disabled because of its power and ease of abuse.

Answer: What're some good ways of notifying a perl script of an incoming email?
contributed by superfrink

tye pointed out the .forward file. I don't believe qmail uses that file. Instead the ~/.qmail file gets used. See the dot-qmail man page for details about the .qmail file. Read the man page because your program's exit codes are important to qmail. My /home/frink/.qmail file looks like this:

| /home/frink/scripts/email-spam-keywords.pl ./Mailbox
Answer: What're some good ways of notifying a perl script of an incoming email?
contributed by solszew

If you use sendmail, you can build a perl milter - look at the source code for "mimedefang", or visit www.milter.org for details regarding milters in general.

Please (register and) log in if you wish to add an answer



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • Outside of code tags, you may need to use entities for some characters:
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Chatterbox?
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others chilling in the Monastery: (14)
    As of 2014-04-17 10:10 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      April first is:







      Results (443 votes), past polls