[Rspamd-Users] spamassassin meta support
Steve Sturges (ststurge)
ststurge at cisco.com
Wed Jan 15 20:56:20 UTC 2020
Hi-
I’ve been playing around with rspamd and have a question about the spamassassin plugin…
I have a few meta rules that are of two different forms:
meta X (Z - Y) > 0.1
meta D (A + 0.25 * B + 0.5 * C) >= 1
When I load them into rspamd using the spamassassin plugin, they are not parsing properly, and I get an error “Cannot parse expression
(Z - Y) > 0.1“ and “Cannot parse expression (A+ 0.25 * B + 0.5 * C) >= 1” respectively.
Near as I can tell from the code, with the 1st form, the plugin and expression parser does not handle the - as an arithmetic operator the same way it does with +. Is this accurate? Are there alternatives in converting the meta expressions? Or plans to add support for this in the future?
For the 2nd example, I have tried swapping the order, making it (A + B * 0.25 + C * 0.5) >= 1, but still get an error. Step through the debugger, the error message comes back as “Cannot parse atom: callback function failed to parse ‘.25 + C * 0.5) >= 1’”, which implies that the combination of addition and multiplication as part of the expression itself is not working as I expect.
Any suggestions from people who have migrated from spamassassin to rspamd?
Thanks!
More information about the Users
mailing list