[Rspamd-Users] Finetune MIME_BAD_EXTENSION : reject message

Sandy Drobic rspamd at drobic.de
Tue Mar 2 09:52:43 UTC 2021


Blacklisting forbidden extensions works well, now I would like to configure
the reject message to tell the sender which extension triggered the reject.

At the moment I can only give a static reply.

 file_extension_blacklist {
      type = "filename";
      filter = "extension";
      map = "${LOCAL_CONFDIR}/local.d/file_extension_blacklist.map";
      symbol = "FILE_EXTENSION_BLACKLISTED";
      prefilter = true;
      action = "reject";
      message = "attachment type not allowed";
}

But when I looked in the webinterface I saw that the blocked extension does
appear in the history line:

Symbols:

*ASN* (0) [asn:20676, ipnet:83.236.0.0/16, country:DE]
*FILE_EXTENSION_BLACKLISTED* (0) [cmd]

Is it possible to extend the message to include this Symbol?
In this testcase I only sent a message with a single attachment, but if an
Archive with many files is sent it is a bit cumbersome to guess which file has
triggered the reject without a hint.

Greetings Sandy



More information about the Users mailing list