[Rspamd-Users] Multimap module body content filter with Redis, not work

Vsevolod Stakhov vsevolod at rspamd.com
Mon Jan 21 12:32:06 UTC 2019


What don't you understand here? Redis does not support partial matching
or regular expressions so you cannot use it for body patterns like you want.

On 21/01/2019 12:05, Emanuel Gonzalez wrote:
> Hello,
> 
> into the redis monitor, i see this
> 
> 1548071669.042355 [0 [::1]:48442] "HGET" "body_blocked" "\n--_000_SC1P215MB00642CC49A95240B13D7955EB49F0SC1P215MB0064LAMP_\nContent-Type: text/plain; charset=\"iso-8859-1\"\nContent-Transfer-Encoding: quoted-printable\n\npalabraspam01\n\n--_000_SC1P215MB00642CC49A95240B13D7955EB49F0SC1P215MB0064LAMP_\nContent-Type: text/html; charset=\"iso-8859-1\"\nContent-Transfer-Encoding: quoted-printable\n\n<html>\n<head>\n<meta http-equiv=3D\"Content-Type\" content=3D\"text/html; charset=3Diso-8859-=\n1\">\n<style type=3D\"text/css\" style=3D\"display:none;\"> P {margin-top:0;margin-bo=\nttom:0;} </style>\n</head>\n<body dir=3D\"ltr\">\n<div style=3D\"font-family: Calibri, Helvetica, sans-serif; font-size: 12pt;=\n color: rgb(0, 0, 0);\">\npalabraspam01<br>\n</div>\n</body>\n</html>\n\n--_000_SC1P215MB00642CC49A95240B13D7955EB49F0SC1P215MB0064LAMP_--\n"
> 
> In the hashkey i set this:
> 
> redis-cli hgetall "body_blocked"
> 
> 5) "palabraspam01"
> 6) "1"
> 
> 
> I understand in the redis log, the "palabraspam01" pattern is being detected but a score is not assigned.
> 
> symbol "BODY_CONTENT_BLK" {
> score = 30.0;
> one_shot = true;
> 
> 
> Someone could help me because I can not understand where the problem is.
> 
> 
> ________________________________
> De: Users <users-bounces at lists.rspamd.com> en nombre de Andrzej Marszalek <hipotures at gmail.com>
> Enviado: lunes, 21 de enero de 2019 8:19
> Para: User questions
> Asunto: Re: [Rspamd-Users] Multimap module body content filter with Redis, not work
> 
> redis-cli monitor ?
> 
> On Mon, Jan 21, 2019 at 12:00 PM Emanuel Gonzalez <
> emanuel_gonzalez at live.com.ar> wrote:
> 
>> Hello, any ideas for this issue.?
>>
>> ________________________________
>> De: Emanuel Gonzalez
>> Enviado: viernes, 18 de enero de 2019 8:10
>> Para: User questions
>> Asunto: Multimap module body content filter with Redis, not work
>>
>> Hello, i have a simple question.
>>
>> I create a filter to map into the body, but not work. I have other filters
>> reading a redis database and they work perfectly.
>>
>> Here my config:
>>
>> BODY_CONTENT_TEST {
>>         type = "content";
>>         filter = "body";
>>         map = "redis://body_blocked";
>>     }
>>
>> [root at vpsx /etc/rspamd/local.d] # redis-cli hgetall body_blocked
>> 1) "thisisspamforme"
>> 2) "1"
>>
>> BODY:
>>
>> === Trying mail.mydomain.tk:25...
>> === Connected to mail.mydomain.tk.
>> <-  220-mydomain.tk ESMTP Exim 4.87_1 #2 Fri, 18 Jan 2019 07:56:00 -0300
>> <-  220-  We do not authorize the use of this system to transport
>> unsolicited,
>> <-  220   and/or bulk e-mail.
>>  -> EHLO egonzalez.dat
>> <-  250-mydomain.tk Hello egonzalez [x.x.x.x]
>> <-  250-SIZE 52428800
>> <-  250-8BITMIME
>> <-  250-PIPELINING
>> <-  250-AUTH LOGIN
>> <-  250-STARTTLS
>> <-  250 HELP
>>  -> MAIL FROM:<soyspam at wtf.com>
>> <-  250 OK
>>  -> RCPT TO:<user at mydomain.tk>
>> <-  250 Accepted
>>  -> DATA
>> <-  354 Enter message, ending with "." on a line by itself
>>  -> Date: Fri, 18 Jan 2019 07:56:00 -0300
>>  -> To: user at mydomain.tk
>>  -> From: soyspam at wtf.com
>>  -> Subject: Subject Spam
>>  -> Message-Id: <20190118075600.030711 at egonzalez>
>>  -> X-Mailer: swaks v20170101.0 jetmore.org/john/code/swaks/
>>  ->
>>  -> thisisspamforme
>>  ->
>>  -> .
>> <-  250 OK id=1gkRoe-0001YI-8h
>>  -> QUIT
>> <-  221 mydomain.tk closing connection
>> === Connection closed with remote host.
>>
>>
>> The command "rspamd configtest" the command not unfolds any error.
>>
>> Any ideas.?
>>
>> Regards.!!
>> --
>> Users mailing list
>> Users at lists.rspamd.com
>> https://lists.rspamd.com/mailman/listinfo/users
>>
> --
> Users mailing list
> Users at lists.rspamd.com
> https://lists.rspamd.com/mailman/listinfo/users
> 



More information about the Users mailing list