From 9bfb73a6c4a06f351a7500fefe49d0851ff6a0b9 Mon Sep 17 00:00:00 2001 From: Jeremy Harris Date: Sat, 3 Mar 2018 18:45:23 +0000 Subject: [PATCH] Testsuite: for DKIM sha512 verify, use a test signed mail produced by Exim This is a temporary measure until Mail::DKIM::Signer can handle rsa-sha512 - it gives us the internal consistency check but not we would like the independent confirmation of correctness --- test/log/4503 | 6 +++--- test/log/4504 | 6 +++--- test/scripts/4500-DKIM/4503 | 22 +++++++++++----------- test/scripts/4500-DKIM/4504 | 22 +++++++++++----------- 4 files changed, 28 insertions(+), 28 deletions(-) diff --git a/test/log/4503 b/test/log/4503 index c91c79650..6bc3a5b26 100644 --- a/test/log/4503 +++ b/test/log/4503 @@ -2,6 +2,6 @@ ******** SERVER ******** 1999-03-02 09:44:33 exim x.yz daemon started: pid=pppp, no queue runs, listening for SMTP on port 1225 1999-03-02 09:44:33 10HmaX-0005vi-00 signer: test.ex bits: 1024 -1999-03-02 09:44:33 10HmaX-0005vi-00 DKIM: d=test.ex s=sel c=simple/simple a=rsa-sha512 b=1024 [verification failed - body hash mismatch (body probably modified in transit)] -1999-03-02 09:44:33 10HmaX-0005vi-00 Authentication-Results: myhost.test.ex;\n dkim=fail (body hash mismatch; body probably modified in transit)\n header.d=test.ex header.s=sel header.a=rsa-sha512 -1999-03-02 09:44:33 10HmaX-0005vi-00 <= CALLER@bloggs.com H=(xxx) [127.0.0.1] P=smtp S=sss id=qwerty1234@disco-zombie.net +1999-03-02 09:44:33 10HmaX-0005vi-00 DKIM: d=test.ex s=sel c=relaxed/relaxed a=rsa-sha512 b=1024 [verification succeeded] +1999-03-02 09:44:33 10HmaX-0005vi-00 Authentication-Results: myhost.test.ex;\n dkim=pass header.d=test.ex header.s=sel header.a=rsa-sha512 +1999-03-02 09:44:33 10HmaX-0005vi-00 <= CALLER@bloggs.com H=(xxx) [127.0.0.1] P=smtp S=sss DKIM=test.ex id=E10HmaY-0005vi-00@myhost.test.ex diff --git a/test/log/4504 b/test/log/4504 index 5af68d0dd..6bc3a5b26 100644 --- a/test/log/4504 +++ b/test/log/4504 @@ -2,6 +2,6 @@ ******** SERVER ******** 1999-03-02 09:44:33 exim x.yz daemon started: pid=pppp, no queue runs, listening for SMTP on port 1225 1999-03-02 09:44:33 10HmaX-0005vi-00 signer: test.ex bits: 1024 -1999-03-02 09:44:33 10HmaX-0005vi-00 DKIM: d=test.ex s=sel2 c=simple/simple a=rsa-sha512 b=1024 [verification failed - body hash mismatch (body probably modified in transit)] -1999-03-02 09:44:33 10HmaX-0005vi-00 Authentication-Results: myhost.test.ex;\n dkim=fail (body hash mismatch; body probably modified in transit)\n header.d=test.ex header.s=sel2 header.a=rsa-sha512 -1999-03-02 09:44:33 10HmaX-0005vi-00 <= CALLER@bloggs.com H=(xxx) [127.0.0.1] P=smtp S=sss id=qwerty1234@disco-zombie.net +1999-03-02 09:44:33 10HmaX-0005vi-00 DKIM: d=test.ex s=sel c=relaxed/relaxed a=rsa-sha512 b=1024 [verification succeeded] +1999-03-02 09:44:33 10HmaX-0005vi-00 Authentication-Results: myhost.test.ex;\n dkim=pass header.d=test.ex header.s=sel header.a=rsa-sha512 +1999-03-02 09:44:33 10HmaX-0005vi-00 <= CALLER@bloggs.com H=(xxx) [127.0.0.1] P=smtp S=sss DKIM=test.ex id=E10HmaY-0005vi-00@myhost.test.ex diff --git a/test/scripts/4500-DKIM/4503 b/test/scripts/4500-DKIM/4503 index aca19583b..2c501a4e6 100644 --- a/test/scripts/4500-DKIM/4503 +++ b/test/scripts/4500-DKIM/4503 @@ -22,18 +22,18 @@ RCPT TO: ??? 250 DATA ??? 354 -DKIM-Signature: v=1; a=rsa-sha512; c=simple/simple; d=test.ex; h=from:to - :date:message-id:subject; s=sel; bh=3UbbJTudPxmejzh7U1Zg33U3QT+1 - 6kfV2eOTvMeiEis=; b=xQSD/JMqz0C+xKf0A1NTkPTbkDuDdJbpBuyjjT9iYvyP - Zez+xl0TkoPobFGVa6EN8+ZeYV18zjifhtWYLSsNmPinUtcpKQLG1zxAKmmS0JEh - +qihlWbeGJ5+tK588ugUzXHPj+4JBW0H6kxHvdH0l2SlQE5xs/cdggnx5QX5USY= -From: mrgus@text.ex -To: bakawolf@yahoo.com -Date: Thu, 19 Nov 2015 17:00:07 -0700 -Message-ID: -Subject: simple test +DKIM-Signature: v=1; a=rsa-sha512; q=dns/txt; c=relaxed/relaxed; d=test.ex; + s=sel; h=From:From; bh=6B2m0DINYQYGHTvmDYQAfAm/wCDFh+Oj57jE2G4jz4nAeJfmjTB6tz + me+A5nT6AQ4J3N47vffXLG1exv8bzFZw==; b=YFIC4khvqvXRd8I3r3YTdQqG/SbtDIAYTYVkIo3 + W7Qe+42eI+w1koPY+ocPtZeRBWWjGVbnZNtof7s5x0sRc6fSDZJAQu6RjnP2xEJWsivowXBMuu8id + PtqcDhP/3Q/0W85VMalfSC7eCgpnNxfn73ZjPuBZFCc1wMVh5nUmUvo=; +From: nobody@example.com +Message-Id: +Sender: CALLER_NAME +Date: Tue, 2 Mar 1999 09:44:33 +0000 + +content -This is a simple test. . ??? 250 QUIT diff --git a/test/scripts/4500-DKIM/4504 b/test/scripts/4500-DKIM/4504 index ccc4d6ebe..39699dbe2 100644 --- a/test/scripts/4500-DKIM/4504 +++ b/test/scripts/4500-DKIM/4504 @@ -22,18 +22,18 @@ RCPT TO: ??? 250 DATA ??? 354 -DKIM-Signature: v=1; a=rsa-sha512; c=simple/simple; d=test.ex; h=from:to - :date:message-id:subject; s=sel2; bh=3UbbJTudPxmejzh7U1Zg33U3QT+1 - 6kfV2eOTvMeiEis=; b=xQSD/JMqz0C+xKf0A1NTkPTbkDuDdJbpBuyjjT9iYvyP - Zez+xl0TkoPobFGVa6EN8+ZeYV18zjifhtWYLSsNmPinUtcpKQLG1zxAKmmS0JEh - +qihlWbeGJ5+tK588ugUzXHPj+4JBW0H6kxHvdH0l2SlQE5xs/cdggnx5QX5USY= -From: mrgus@text.ex -To: bakawolf@yahoo.com -Date: Thu, 19 Nov 2015 17:00:07 -0700 -Message-ID: -Subject: simple test +DKIM-Signature: v=1; a=rsa-sha512; q=dns/txt; c=relaxed/relaxed; d=test.ex; + s=sel; h=From:From; bh=6B2m0DINYQYGHTvmDYQAfAm/wCDFh+Oj57jE2G4jz4nAeJfmjTB6tz + me+A5nT6AQ4J3N47vffXLG1exv8bzFZw==; b=YFIC4khvqvXRd8I3r3YTdQqG/SbtDIAYTYVkIo3 + W7Qe+42eI+w1koPY+ocPtZeRBWWjGVbnZNtof7s5x0sRc6fSDZJAQu6RjnP2xEJWsivowXBMuu8id + PtqcDhP/3Q/0W85VMalfSC7eCgpnNxfn73ZjPuBZFCc1wMVh5nUmUvo=; +From: nobody@example.com +Message-Id: +Sender: CALLER_NAME +Date: Tue, 2 Mar 1999 09:44:33 +0000 + +content -This is a simple test. . ??? 250 QUIT -- 2.25.1