[Rspamd-Users] phpmail() generated mail is not signed regardless of sign_local=true
Johannes Rohr
johannes at rohr.org
Mon Jan 22 13:24:40 UTC 2024
Am 22.01.24 um 11:44 schrieb Carsten Rosenberg:
> [
[...]
>
> It would be helpful if you have some logs and dkim_signing config for
> us. As I also asked in the chat. Was the mail scanned at all by rspamd?
I'm trying to generate logs by executing a php script that calls the
mail() function, but somehow, those mails get properly signed and thus
accepted by google. So I still have to understand what Wordpress does
differently, using the same function. This is confusing.
Oh, well, now I made another test. This time, the $from variable in the
script is a gmail address, and that mail gets promptly rejected by Google.
This is what the rspamd log says:
2024-01-22 14:20:01 #1532799(normal) <d5a4dd>; task;
rspamd_task_write_log: id: <20240122132001.EDD2137D6211B at mail.**>, qid:
<EDD2137D6211B>, ip: 127.0.0.1, from: <**@mail.**>, (default: F (no
action): [0.19/13.00]
[FORGED_SENDER(0.30){***@gmail.com;**@mail.***;},MIME_GOOD(-0.10){text/plain;},ARC_NA(0.00){},FREEMAIL_ENVRCPT(0.00){gmail.com;},FREEMAIL_FROM(0.00){gmail.com;},FREEMAIL_TO(0.00){gmail.com;},FROM_NEQ_ENVFROM(0.00){***@gmail.com;jr at mail.rooot.de;},FROM_NO_DN(0.00){},GENERIC_REPUTATION(0.00){-0.30494941150341;},MIME_TRACE(0.00){0:+;},MISSING_XM_UA(0.00){},RCPT_COUNT_ONE(0.00){1;},RCVD_COUNT_ZERO(0.00){0;},SINGLE_SHORT_PART(0.00){},TO_DN_NONE(0.00){},TO_EQ_FROM(0.00){},TO_MATCH_ENVRCPT_ALL(0.00){}]),
len: 234, time: 3.335ms, dns req: 2, digest:
<d94911cad8a7fe13912128a127bbb1f7>, rcpts: <***@gmail.com>, mime_rcpts:
<***@gmail.com>
2024-01-22 14:20:01 #1532799(normal) <d5a4dd>; task;
rspamd_protocol_http_reply: regexp statistics: 0 pcre regexps scanned, 2
regexps matched, 176 regexps total, 37 regexps cached, 0B scanned using
pcre, 367B scanned total
So I guess, this is correct then, and the solution is to ensure that
wordpress does not use a forged sender address. I'm not sure how to do that.
>
> If you are using Postfix and PHP defaults mail() function the mail
> will not be scanned without setting 'non_smtpd_milters'
That setting was in place already.
Johannes
>
>
> Carsten
More information about the Users
mailing list