procmail
[Top] [All Lists]

Re: matching inline htnl email

2001-09-16 13:41:41
On Sun, 16 Sep 2001, Eric Smith wrote:

I am having some difficulties with the procmail regex, could someone
please give me a recipe to match this kind of spam. html without any
multi-part headers.

:0
* ^Content-Type: text/html
{
 # Do whatever
}

On Sun, 16 Sep 2001, Stig Brautaset wrote:

Yeah. A "friend" that uses hotmail have started to send me such messages
lately. I would be delighted if it was possible to run lynx -dump on the
message body of such messages before they were written to my mailbox
(preferably leaving an one-liner saying "[html stripped]" at the top or
something). This would save me both harddisk space and grief.

The following should do it, if your system supports the /dev/fd/ devices.
If not you'll have to write the body to a tempfile and run lynx -dump on
that file.

:0
* ^Content-Type: text/html
{
 :0bfW
 | (echo "[html stripped]"; lynx -dump /dev/fd/0)

 :0ahfw
 | formail -i"Content-Type: text/plain"
}

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>