• procmail to identify and drop attachments?

    From Mathias Koerber@21:1/5 to All on Tue Oct 10 07:46:51 2017
    Does anyone know if procmail can
    a) identify all attachments of an email (eg my running them through
    an md5 checksum) and if matched against a database(file)
    b) remove that attachment

    c) same for in-line images etc

    This would be good to delete often repeated attachments users
    add to their mails that only contain company logos etc

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Eli the Bearded@21:1/5 to mathias@koerber.org on Tue Oct 10 19:24:31 2017
    In comp.mail.misc, Mathias Koerber <mathias@koerber.org> wrote:
    Does anyone know if procmail can
    a) identify all attachments of an email (eg my running them through
    an md5 checksum) and if matched against a database(file)
    b) remove that attachment
    c) same for in-line images etc

    The short answer is "No."

    The longer answer is "Procmail can be used to run a tool that does that,
    and be configured to only try on mail with attachments or meeting
    certain criteria."

    Procmail has *no native MIME support*, and all modern email using
    attached or inline images does so with MIME.

    I know some people who use "MIME Defang" run from Procmail. A solution
    like that may work for you.

    I personally don't delete or strip attachments automatically, but do
    have macros in my email program to help me do that at read time (if I
    don't want to just outright delete the whole message).

    As for your mailling list question: I don't know, so I didn't answer. I
    used to be on the procmail list, but that was at least a decade ago.

    Elijah
    ------
    writes his own MIME tools

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)