Are you looking for just if it has an attachment, or if it is a specific type?

If it is specific types, ban them, and set the Final destiny to pass. That way it gets through, regardless of it being banned. Banning adds a header saying that it was banned, and the reason for it being banned.

If you set the final destiny to pass, then it will still get to your other content filter.


Or are you looking to outright block certain attachment types, and then tag others?


On 04/20/2017 10:53 AM, d...@tydnet.org wrote:
Hi list,

thanks for your time and advices.

I have a project filtering emails, chaining filters, first with amavis and clamd and after with a custom content_filter in postfix. The second filter depends on the headers set by amavis.

I have a use case when I need to set a custom header in the email if it contains certain kinds of attachments (extension, or type, or name, etc), lets say, if the email has a .doc file I amavis should set a new header Has-attachment: yes, for instance.

I would really appreciate your advices.

Is it doable with amavis? I'm using amavisd-new from Centos7: amavisd-new-2.10.1-5.el7.noarch

There is any amavisd package to query the list of attachments, types and names?

Any documentation with examples will be great, I've seen amavisd-custom.conf, I think it could be the starting point.

any comments are welcome,


thanks again.

D.



Reply via email to