Whitelisting File Extension Types?

Damian amavis at arcsin.de
Thu Mar 24 23:26:09 CET 2022


> I am not sure why it is finding an "asc" file as only a PDF was attached.

The banned files mechanism checks mime parts, not only attachments.

> Furthermore, even if I added ".asc" to the list above, it is still flagging the email as having banned content.
A text-file attachment internally transforms to a list of strings:

> ["multipart/mixed","application/octet-stream",".asc","file.txt"]

Your default policy has to handle those mime-types appropriately.

Example of a PDF inside a zip archive:

> ["multipart/mixed","application/octet-stream",".zip","file.zip",".pdf","file.pdf"]

A plain text body of a mail without attachments:

> ["text/plain",".asc"]
Your case probably has been:

> ["multipart/mixed","text/plain",".asc"]


More information about the amavis-users mailing list