Luigi.

> I would like to audit the attachments that goes trough a mail server,
> more specifically I would like to start a script shell each time amavis
> processes some type of attachment, depending on its extension.
>
> I was thinking of using the antivirus interface,

ok

> but how can I pass to a script shell also the sender and recipient?

You can't, at least not without some hack.

But for your purpose perhaps a cleaner solution is to use
the new custom hooks - see sample file amavisd-custom.conf.
It offers access to all information about a message,
including sender, recipients, size, ..., and also an open
file handle attached to a file containing the complete
message (use seek(0,0) to rewind, are read it if needed).
If you prefer access to decoded mail parts as individual
files, they are stored in a subdirectory 'parts'
under a temporary directory $msginfo->mail_tempdir.

See what other information is available in objects of class
Amavis::In::Message::PerRecip and Amavis::In::Message.

  Mark

-------------------------------------------------------------------------
SF.Net email is sponsored by:
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
AMaViS-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/amavis-user
AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3
AMaViS-HowTos:http://www.amavis.org/howto/

Reply via email to