[Mimedefang] replacing the attachment in MIMEDefang

Steffen Kaiser skmimedefang at smail.inf.fh-bonn-rhein-sieg.de
Wed Nov 14 02:31:46 EST 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wed, 14 Nov 2007, raan wrote:

> Can you tell me how can I only replace the attachment of the mail with
> another document.

I'm not aware of a replace function, but you can add a new attachment with 
action_add_part() in filter_end() and remove an attachment with 
action_drop() in filter(). To pass the mangled attachment from filter() to 
filter_end() dump it into your own subdirectory of '.' (or $CWD) and pick 
them up in filter_end().

However, take a look at sub action_replace_with_warning in mimedefang.pl - 
you can model an action_replace_with_entity() from it.

Bye,

- -- 
Steffen Kaiser
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iQEVAwUBRzqkZegJIbZtwg6XAQKwvggApIHkZiBBy2yV4ta+orIDGGvIPHLzIW+3
BiDD2MW1Zjo9s7DVBwa5Me0RqTz0ZRrj/BcxOgyJe/Jy8HP4AM9QyzMNgqTnGzKA
jYjiaCL8rYxT4GyYshO55sNX52NyhiJ8NWre8YPGgrqsFlEdVN7MUFjIQRZlBJ0i
DxgySfnZWh/hgzIMXfFg4uA5629SoTNBEPl5NMqXFZmHTc7BePi/WIgfWi3KeCVX
soqSAuZLOMC2TgjKmuZ9ZtUY8lCiy5MbjLJu7VvwssVH4b8rp9T62pgqxUuap1+d
/uXf9SfjnDEH2xYuAUMvvO81lq3NheVU01mLvWwqgfDheJRPLO8MSw==
=og5f
-----END PGP SIGNATURE-----


More information about the MIMEDefang mailing list