[Rspamd-Users] Lua recipe to add urls from message content

jose.celestino at gmail.com jose.celestino at gmail.com
Mon May 6 13:15:15 UTC 2024


Hi,

On Mon, May 6, 2024 at 12:56 PM Andrew Lewis via Users
<users at lists.rspamd.com> wrote:
>
> Do you use a contemporary version of Rspamd? Could you try newer
> versions? The easiest way is probably Docker-
>  https://hub.docker.com/r/rspamd/rspamd

rspamd version is git:c8f3600c7 (git pulled and compiled a few hours ago).

> If you have messages containing clickable URLs that are not extracted
> by Rspamd that's considered a bug and could be reported as such (with
> message samples please).

The clickable part is debatable. I guess that this spam continues
because there are (a few? plenty?) MUAs that parse the string as a
url.

Upon further investigation:

- the messages have a multipart/alternative with text/plain and text/html
- the text/html is just a bit of html with the text/plain part (which
includes the url) copy + pasted in a div
- if I just include the text/plain part the url is extracted
- if I just include the text/html part the url is not extracted

Being text/html it is not trying to match url on untagged text? That
doesn't explain why it seems to skip the text/plain when parsing
(because of the multipart/alternative?).

Will anonymize a sample and open a bug report.

> URLs can be added to the scan artificially using the
> `task:inject_url()` method but it needs to happen early in processing
> at which point you wouldn't want to be calling SpamAssassin.

No, it was one or the other: either the url extraction+score or the
spamassassin rule.


More information about the Users mailing list