Check DKIM Authentication-Results (#3583)

Fix #3507

Note that this is not intended for a release at this point! We first have to test whether it runs stable enough. If we want to make a release while we are not confident enough in authres-checking, then we have to disable it.

BTW, most of the 3000 new lines are in `test_data/messages/dkimchecks...`, not the actual code

da3a4b94 adds the results to the Message info. It currently does this by adding them to `hop_info`. Maybe we should rename `hop_info` to `extra_info` or something; this has the disadvantage that we can't rename the sql column name though.

Follow-ups for this could be:
- In `update_authservid_candidates()`: Implement the rest of the algorithm @hpk42 and me thought about. What's missing is remembering how sure we are that these are the right authserv-ids. Esp., when receiving a message sent from another account at the same domain, we can be quite sure that the authserv-ids in there are the ones of our email server. This will make authres-checking work with buzon.uy, disroot.org, yandex.ru, mailo.com, and riseup.net.
- Think about how we present this to the user - e.g. currently the only change is that we don't accept key changes, which will mean that the small lock on the message is not shown.
- And it will mean that we can fully enable AEAP, after revisiting the security implications of this, and assuming everyone (esp. @link2xt who pointed out the problems in the first place) feels comfortable with it.
This commit is contained in:
Hocuri
2022-10-28 12:15:37 +02:00
committed by GitHub
parent d8bc3769a5
commit b1c6c40fa7
326 changed files with 3304 additions and 42 deletions

View File

@@ -0,0 +1,6 @@
From: <alice@aol.com>
To: <alice@e.email>
Authentication-Results: mail3.ecloud.global;
dkim=pass header.d=aol.com header.s=a2048 header.b=HlBq3Lmt;
dmarc=pass (policy=reject) header.from=aol.com;
spf=pass (mail3.ecloud.global: domain of alice@aol.com designates 77.238.178.146 as permitted sender) smtp.mailfrom=alice@aol.com

View File

@@ -0,0 +1,6 @@
From: <alice@buzon.uy>
To: <alice@e.email>
Authentication-Results: mail3.ecloud.global;
dkim=pass header.d=buzon.uy header.s=2019 header.b=XfN4sE6M;
dmarc=pass (policy=reject) header.from=buzon.uy;
spf=pass (mail3.ecloud.global: domain of alice@buzon.uy designates 185.101.93.79 as permitted sender) smtp.mailfrom=alice@buzon.uy

View File

@@ -0,0 +1,6 @@
From: <alice@delta.blinzeln.de>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=none;
dmarc=none;
spf=none (mail2.ecloud.global: domain of alice@delta.blinzeln.de has no SPF policy when checking 192.162.87.117) smtp.mailfrom=alice@delta.blinzeln.de

View File

@@ -0,0 +1,6 @@
From: <alice@disroot.org>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=pass header.d=disroot.org header.s=mail header.b=Vf7JxMcu;
dmarc=pass (policy=quarantine) header.from=disroot.org;
spf=pass (mail2.ecloud.global: domain of alice@disroot.org designates 178.21.23.139 as permitted sender) smtp.mailfrom=alice@disroot.org

View File

@@ -0,0 +1,7 @@
From: <alice@fastmail.com>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=pass header.d=fastmail.com header.s=fm2 header.b=bQ080jJU;
dkim=pass header.d=messagingengine.com header.s=fm2 header.b=FVyMuSGb;
dmarc=pass (policy=none) header.from=fastmail.com;
spf=pass (mail2.ecloud.global: domain of alice@fastmail.com designates 66.111.4.28 as permitted sender) smtp.mailfrom=alice@fastmail.com

View File

@@ -0,0 +1,6 @@
From: <alice@gmail.com>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=pass header.d=gmail.com header.s=20210112 header.b=f2AxVaaA;
dmarc=pass (policy=none) header.from=gmail.com;
spf=pass (mail2.ecloud.global: domain of alice@gmail.com designates 2a00:1450:4864:20::443 as permitted sender) smtp.mailfrom=alice@gmail.com

View File

@@ -0,0 +1,9 @@
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none;
dkim=none; arc=none
From: <alice@hotmail.com>
To: <alice@e.email>
Authentication-Results: mail3.ecloud.global;
dkim=pass header.d=hotmail.com header.s=selector1 header.b="ECc21y/J";
arc=pass ("microsoft.com:s=arcselector9901:i=1");
dmarc=pass (policy=none) header.from=hotmail.com;
spf=pass (mail3.ecloud.global: domain of alice@hotmail.com designates 40.92.68.54 as permitted sender) smtp.mailfrom=alice@hotmail.com

View File

@@ -0,0 +1,6 @@
From: <alice@icloud.com>
To: <alice@e.email>
Authentication-Results: mail3.ecloud.global;
dkim=pass header.d=icloud.com header.s=1a1hai header.b=enuQcpfH;
dmarc=pass (policy=quarantine) header.from=icloud.com;
spf=pass (mail3.ecloud.global: domain of alice@icloud.com designates 17.57.155.16 as permitted sender) smtp.mailfrom=alice@icloud.com

View File

@@ -0,0 +1,6 @@
From: <alice@ik.me>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=pass header.d=ik.me header.s=20200325 header.b=E5lGMzkQ;
dmarc=pass (policy=reject) header.from=ik.me;
spf=pass (mail2.ecloud.global: domain of alice@ik.me designates 83.166.143.168 as permitted sender) smtp.mailfrom=alice@ik.me

View File

@@ -0,0 +1,6 @@
From: <alice@mail.de>
To: <alice@e.email>
Authentication-Results: mail3.ecloud.global;
dkim=pass header.d=mail.de header.s=mailde202009 header.b=vVqLo0H5;
dmarc=pass (policy=none) header.from=mail.de;
spf=pass (mail3.ecloud.global: domain of alice@mail.de designates 2001:868:100:600::216 as permitted sender) smtp.mailfrom=alice@mail.de

View File

@@ -0,0 +1,6 @@
From: <alice@mail.ru>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=pass header.d=mail.ru header.s=mail4 header.b=heZ1ZiKV;
dmarc=pass (policy=reject) header.from=mail.ru;
spf=pass (mail2.ecloud.global: domain of alice@mail.ru designates 94.100.181.251 as permitted sender) smtp.mailfrom=alice@mail.ru

View File

@@ -0,0 +1,6 @@
From: <alice@mailo.com>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=pass header.d=mailo.com header.s=mailo header.b=HnhKNKUg;
dmarc=pass (policy=none) header.from=mailo.com;
spf=pass (mail2.ecloud.global: domain of alice@mailo.com designates 213.182.54.15 as permitted sender) smtp.mailfrom=alice@mailo.com

View File

@@ -0,0 +1,9 @@
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none;
dkim=none; arc=none
From: <alice@outlook.com>
To: <alice@e.email>
Authentication-Results: mail3.ecloud.global;
dkim=pass header.d=outlook.com header.s=selector1 header.b=MqNsAJKf;
arc=pass ("microsoft.com:s=arcselector9901:i=1");
dmarc=pass (policy=none) header.from=outlook.com;
spf=pass (mail3.ecloud.global: domain of alice@outlook.com designates 40.92.66.84 as permitted sender) smtp.mailfrom=alice@outlook.com

View File

@@ -0,0 +1,6 @@
From: <alice@posteo.de>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=pass header.d=posteo.de header.s=2017 header.b=bMopHaXo;
dmarc=pass (policy=none) header.from=posteo.de;
spf=pass (mail2.ecloud.global: domain of alice@posteo.de designates 185.67.36.66 as permitted sender) smtp.mailfrom=alice@posteo.de

View File

@@ -0,0 +1,6 @@
From: <alice@riseup.net>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=pass header.d=riseup.net header.s=squak header.b="GUmo/IlI";
dmarc=pass (policy=none) header.from=riseup.net;
spf=pass (mail2.ecloud.global: domain of alice@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=alice@riseup.net

View File

@@ -0,0 +1,6 @@
From: <alice@yahoo.com>
To: <alice@e.email>
Authentication-Results: mail2.ecloud.global;
dkim=pass header.d=yahoo.com header.s=s2048 header.b=mRSwanl2;
dmarc=pass (policy=reject) header.from=yahoo.com;
spf=pass (mail2.ecloud.global: domain of alice@yahoo.com designates 77.238.178.146 as permitted sender) smtp.mailfrom=alice@yahoo.com

View File

@@ -0,0 +1,3 @@
From: forged-authres-added@example.com
Authentication-Results: mail2.ecloud.global;
Authentication-Results: aaa.com; dkim=pass header.i=@example.com