procmail
[Top] [All Lists]

Re: converting Html to Plaintext

2005-08-17 09:30:32
On Wed, Aug 17, 2005 at 07:50:24AM -0500, antenneX wrote:

From: "Dallman Ross" <dman(_at_)nomotek(_dot_)com>

On Wed, Aug 17, 2005 at 11:30:45AM +1200, Volker Kuhlmann wrote:

Unfortunately I can't tell it to leave certain attachments
in, I'm still looking for a program which allows that while
also doing all of the above. I never got much use out of
demime. Suggestions appreciated...

Well, my suggestion would be to have two recipes, the first one
to check what you want in attachments and handle those messages
differently; and the second, through demime or stripmime.

Hi, Dallman. How would you present those 2 recipes as a
single 2-part one and only applies to the "commands" sent to
majordomo...?? Like, subscribe, unsubscribe, help, etc. I think I
could structure one, but it would take a while.

Are the commands in the Subject?  Body?  Do you have a cross-check
to make sure it's not a forgery?  I'm unclear on why attachments
would be coming in to majordomo.  Or do you mean html mail comes
in, and you want to honor the requests in the body?  I'll assume the
last, because it makes the most sense to me.

  :0 fw i  # not sure about the "i," actually
  * { condition to tell if it's majordomo }
  * ^Content-Type:.*html
  | stripmime

If you mean something else, please clarify.

Thanks for any suggestions.  BTW: I also use vsnag.

If you want to allow certain attachment and you've already run
vsnag, you can use some of the vars it has assembled in its run,
presuming it passed through as non-viral-looking.

One is $VS_ATTACH, which is set non-null if vsnag thinks there
was an attachment.

  :0:
  * VS_ATTACH ?? .
  * B ?? filename=".*[.]foo"
  $DEFAULT

would be one highly simple way.

Dallman

____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail