Questions tagged [procmail]

Procmail is a powerful Mail Delivery Agent (MDA) capable of sorting and filtering mail based on rulesets called recipes. It's rather *nix-centric, terse, mature, and proven. However, it is now unmaintained.

Procmail is a versatile mail delivery agent (MDA) for Unix-like systems. If features a simple language for articulating delivery rules (aka recipes) to sort, forward, manipulate, and otherwise process incoming email messages.

Procmail was created in the early 1990s by Stephen R. van den Berg. After his involvement waned, Philip Guenther took over as maintainer, and published some new versions at http://procmail.org/. However, this site is now dead, and as of 2010, Guenther recommends users to switch to alternative tools such as maildrop.

In spite of its age and security issues, Procmail remains popular in some environments.

Resources

172 questions
0
votes
2 answers

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…
Lester Buck
  • 797
  • 6
  • 8
0
votes
1 answer

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…
user14038
0
votes
1 answer

Sendmail/procmail - get mail sender and mail subject, utf8 encoding issues

My .procmailrc (really simple): :0c | $HOME/send_sms.sh "`formail -xFrom:`" "`formail -xSubject:`" So, sender named "mail@domain.com" sends message with subject "Subject test ąść". The script "send_sms.sh" receives: Sender: …
user1209216
  • 7,404
  • 12
  • 60
  • 123
0
votes
1 answer

php imap headesr message_id to FT_UID or in_reply_to to FT_UID

Is there any way that I can find message FT_UID if I have raw message_id (bfd14a45-88ef-4404-b7fd-dbbf8ec8241b@domain.com)? Or in_reply_to raw id (20120717101453.4074313004BD@zumance.pregmatch.org) to FT_UID? Or is there any way that I can pipe…
pregmatch
  • 2,629
  • 6
  • 31
  • 68
0
votes
1 answer

How to forward emails to PHP script?

I'm trying to figure out how I can forward (or pipe) an email to a PHP script using fetchmail. I've never done this and am not even sure if I'm on the right track. From what I've read I think I need to use an MDA to forward the mail. I'm using…
ctown4life
  • 835
  • 1
  • 11
  • 24
-1
votes
1 answer

procmail - using {} won't deliver to mbox

I'm trying to use procmail to tidy up some old email into my thunderbird mbox file, however I can't seem to get it to file into an mbox file when using braces. Doing the simple test below with and without braces provides different outcomes - what am…
-1
votes
1 answer

procmail create a new folder if not exist with name of recipient address

Can someone explain how to get the send to mail address with procmail and extract all up to @example.com and then create a new folder with the name? Example: I collect all mail in one account so the addresses hello@example.com and…
proc
  • 1
-1
votes
1 answer

Email html to csv file

I have one email with html format and need to download it and need to make one csv semicolon field separator result to a new file. Example of the email received: Content-Type: text/html; charset=UTF-8 Thu Jul 11 2019
-1
votes
2 answers

How to split single mail with procmail?

I have a quarantine folder that I periodically have to download and split by recipient inbox or even better split each message in a text file. I have c.a. 10.000 mails per day and I'm coding something with fetchmail and procmail. The problem is that…
Wyatt Gillette
  • 318
  • 3
  • 14
-1
votes
1 answer

Procmail - execute Java file

How can I execute .jar file via procmail? My recipe: :0 * ^Subject.*test * B ?? test | /usr/local/bin/java /home/username/.procmail/printer.jar In present form it doesn't work but if I change executing jar file to forward mail like that: !…
-1
votes
1 answer

Procmail mail to file

i want to configure procmail. Right now i've got code to redirect mails with selected topic from server mail to my mail. It's my code: :0 c *Subject.*ExampleTopic Example@Mail.com I want to copy mail content to selected .txt file on server. How can…
-1
votes
1 answer

global procmailrc and sendmail execution rights

I am setting up procmail on my Debian Jessie mail server with the following global procmail config file…
duxsco
  • 331
  • 2
  • 17
-1
votes
1 answer

Intregrate existing Procmail with with new SpamAssassin

For many, many years, I have successfully been using procmail and it's recipes without issue, and I have many, many recipes. A few weeks ago, my system adopted/started using spamassassin, and now those procmail recipes that have been used for years…
Zaxxon
  • 182
  • 1
  • 4
  • 18
-1
votes
1 answer

Email Forwarding on a unix system using .procmailrc

I need to forward all the incoming mails on a linux system to the folder /home/INBOX. How can I make the mbox of incoming msgs be created in this folder which automatically gets all the mails forwarded here? I am using the following code that is…
Aditya Raman
  • 309
  • 8
  • 19
-1
votes
1 answer

Forward a mail, adding the beginning of the body to the email subject

How can I append the beginng of body to the subject of the mail using e.g. procmail? The body of new mail can be erased.
Marki
  • 660
  • 8
  • 24
1 2 3
11
12