[Rspamd-Users] Announcement: avast.lua virus scanner module for Rspamd
vsevolod at rspamd.com
Thu Jan 30 17:15:58 UTC 2020
On 30/01/2020 15:52, Ralph Seichter wrote:
> Hello list,
> I have written a Lua module allowing Rspamd 2.2 to access the Avast 
> virus scanner, and the sponsor sys4 AG  has agreed to let me offer
> this as an upstream contribution for Rspamd. The code is available at
> and I'd be happy if more people took "avast.lua" for a spin.
>  https://www.avast.com/
>  https://sys4.de/
Thank you for your contribution! Unfortunately, I'm sorry to say but I
cannot accept it into Rspamd nor advice other users to try it.
The main issue is that lua-socket usage is a big *NO WAY* in Rspamd (in
fact, I would say that using *ANY* Lua or C module that is not a part of
Rspamd is usually a mistake).
You literally break almost everything with unpredictable consequences by
doing it as you mix non-blocking and blocking sockets IO. Why lua_tcp
was not enough for your purposes?
This module should also not be a dedicated plugin but a component of
lua_scanners framework. This framweork is also pluggable so the existing
`antivirus` plugin would automatically use a new scanner tye if it is
I would strongly advice to take a look at the existing modules, such as
fprot module .
Please also bear in mind the `lua_util` framework: it has lot's of
helper functions you have written one more time in your plugin.
More information about the Users