Fix build on platforms lacking TIOCOUTQ ioctl
[exim.git] / test / scripts / 4500-DKIM / 4500
1 # DKIM verify, simple canonicalisation
2 #
3 exim -DSERVER=server -DMSIZE='rsa=512 ed25519=250' -bd -oX PORT_D
4 ****
5 #
6 # This should pass.
7 #  - sha1, 1024b
8 # Mail original in aux-fixed/4500.msg1.txt
9 # Sig generated by: perl aux-fixed/dkim/sign.pl --method=simple/simple < aux-fixed/4500.msg1.txt
10 client 127.0.0.1 PORT_D
11 ??? 220
12 HELO xxx
13 ??? 250
14 MAIL FROM:<CALLER@bloggs.com>
15 ??? 250
16 RCPT TO:<a@test.ex>
17 ??? 250
18 DATA
19 ??? 354
20 DKIM-Signature: v=1; a=rsa-sha1; c=simple/simple; d=test.ex; h=from:to
21         :date:message-id:subject; s=sel; bh=OB9dZVu7+5/ufs3TH9leIcEpXSo=; b=
22         PeUA8iBGfStWv+9/BBKkvCEYj/AVMl4e9k+AqWOXKyuEUfHxqAnV+sPnOejpmvT8
23         41kuM4u0bICvK371YvB/yO61vtliRhyqU76Y2e55p2uvMADb3UyDhLyzpco4+yBo
24         1w0AuIxu0VU4TK8UmOLyCw/1hxrh1DcEInbEMEKJ7kI=
25 From: mrgus@text.ex
26 To: bakawolf@yahoo.com
27 Date: Thu, 19 Nov 2015 17:00:07 -0700
28 Message-ID: <qwerty1234@disco-zombie.net>
29 Subject: simple test
30
31 This is a simple test.
32 .
33 ??? 250
34 QUIT
35 ??? 221
36 ****
37 #
38 # This should pass.
39 #  - sha1, 512b
40 # Mail original in aux-fixed/4500.msg1.txt
41 # Sig generated by: perl aux-fixed/dkim/sign.pl --method=simple/simple --selector=ses \
42 #                       --keyfile=aux-fixed/dkim/dkim512.private < aux-fixed/4500.msg1.txt
43 client 127.0.0.1 PORT_D
44 ??? 220
45 HELO xxx
46 ??? 250
47 MAIL FROM:<CALLER@bloggs.com>
48 ??? 250
49 RCPT TO:<a@test.ex>
50 ??? 250
51 DATA
52 ??? 354
53 DKIM-Signature: v=1; a=rsa-sha1; c=simple/simple; d=test.ex; h=from:to
54         :date:message-id:subject; s=ses; bh=OB9dZVu7+5/ufs3TH9leIcEpXSo=; b=
55         cIErF1eueIT9AU4qG54FyT3yrlVDDM7RZnuU6fWTevZpAuMqhYcRO8tU3U4vtKWB
56         +I2vd+F1gzqCzBcRtfLhZg==
57 From: mrgus@text.ex
58 To: bakawolf@yahoo.com
59 Date: Thu, 19 Nov 2015 17:00:07 -0700
60 Message-ID: <qwerty1234@disco-zombie.net>
61 Subject: simple test
62
63 This is a simple test.
64 .
65 ??? 250
66 QUIT
67 ??? 221
68 ****
69 #
70 # This should pass.
71 #  - sha256, 1024b
72 # Mail original in aux-fixed/4500.msg1.txt
73 # Sig generated by: perl aux-fixed/dkim/sign.pl --algorithm=rsa-sha256 \
74 #                       --method=simple/simple < aux-fixed/4500.msg1.txt
75 client 127.0.0.1 PORT_D
76 ??? 220
77 HELO xxx
78 ??? 250
79 MAIL FROM:<CALLER@bloggs.com>
80 ??? 250
81 RCPT TO:<a@test.ex>
82 ??? 250
83 DATA
84 ??? 354
85 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=test.ex; h=from:to
86         :date:message-id:subject; s=sel; bh=3UbbJTudPxmejzh7U1Zg33U3QT+1
87         6kfV2eOTvMeiEis=; b=xQSD/JMqz0C+xKf0A1NTkPTbkDuDdJbpBuyjjT9iYvyP
88         Zez+xl0TkoPobFGVa6EN8+ZeYV18zjifhtWYLSsNmPinUtcpKQLG1zxAKmmS0JEh
89         +qihlWbeGJ5+tK588ugUzXHPj+4JBW0H6kxHvdH0l2SlQE5xs/cdggnx5QX5USY=
90 From: mrgus@text.ex
91 To: bakawolf@yahoo.com
92 Date: Thu, 19 Nov 2015 17:00:07 -0700
93 Message-ID: <qwerty1234@disco-zombie.net>
94 Subject: simple test
95
96 This is a simple test.
97 .
98 ??? 250
99 QUIT
100 ??? 221
101 ****
102 #
103 #
104 # This should pass.  The pubkey dns decord has a additional sha1-only h= field
105 #
106 #  - sha1, 512b
107 # Mail original in aux-fixed/4500.msg1.txt
108 # Sig generated by: perl aux-fixed/dkim/sign.pl --keyfile=aux-fixed/dkim/dkim512.private \
109 #                       --method=simple/simple --selector=ses_sha1 < aux-fixed/4500.msg1.txt
110 client 127.0.0.1 PORT_D
111 ??? 220
112 HELO xxx
113 ??? 250
114 MAIL FROM:<CALLER@bloggs.com>
115 ??? 250
116 RCPT TO:<a@test.ex>
117 ??? 250
118 DATA
119 ??? 354
120 DKIM-Signature: v=1; a=rsa-sha1; c=simple/simple; d=test.ex; h=from:to
121         :date:message-id:subject; s=ses_sha1; bh=OB9dZVu7+5/ufs3TH9leIcE
122         pXSo=; b=hG14R3Eb/f13Pw6J0LmovHAL01KHVmVrTZ7KJrqieYTQemUaseoU2pB
123         7/g8NUwG/AsYoaw3gaAK8PqxSk2lcIQ==
124 From: mrgus@text.ex
125 To: bakawolf@yahoo.com
126 Date: Thu, 19 Nov 2015 17:00:07 -0700
127 Message-ID: <qwerty1234@disco-zombie.net>
128 Subject: simple test
129
130 This is a simple test.
131 .
132 ??? 250
133 QUIT
134 ??? 221
135 ****
136 #
137 #
138 killdaemon
139 #
140 # A verifier that refuses sha1
141 exim -DSERVER=server -DOPTION -DMSIZE='rsa=512 ed25519c=32' -bd -oX PORT_D
142 ****
143 #
144 # This should fail despite being a passing submission above (with the unlimited verifier).
145 #  - sha1, 1024b
146 # Mail original in aux-fixed/4500.msg1.txt
147 # Sig generated by: perl aux-fixed/dkim/sign.pl --method=simple/simple < aux-fixed/4500.msg1.txt
148 client 127.0.0.1 PORT_D
149 ??? 220
150 HELO xxx
151 ??? 250
152 MAIL FROM:<CALLER@bloggs.com>
153 ??? 250
154 RCPT TO:<a@test.ex>
155 ??? 250
156 DATA
157 ??? 354
158 DKIM-Signature: v=1; a=rsa-sha1; c=simple/simple; d=test.ex; h=from:to
159         :date:message-id:subject; s=sel; bh=OB9dZVu7+5/ufs3TH9leIcEpXSo=; b=
160         PeUA8iBGfStWv+9/BBKkvCEYj/AVMl4e9k+AqWOXKyuEUfHxqAnV+sPnOejpmvT8
161         41kuM4u0bICvK371YvB/yO61vtliRhyqU76Y2e55p2uvMADb3UyDhLyzpco4+yBo
162         1w0AuIxu0VU4TK8UmOLyCw/1hxrh1DcEInbEMEKJ7kI=
163 From: mrgus@text.ex
164 To: bakawolf@yahoo.com
165 Date: Thu, 19 Nov 2015 17:00:07 -0700
166 Message-ID: <qwerty1234@disco-zombie.net>
167 Subject: simple test
168
169 This is a simple test.
170 .
171 ??? 250
172 QUIT
173 ??? 221
174 ****
175 killdaemon
176 #
177 #
178 #
179 #
180 #
181 #
182 # With the default keysize minima, a 512b key should fail
183 exim -DSERVER=server -bd -oX PORT_D
184 ****
185 #  - sha1, 512b
186 # Mail original in aux-fixed/4500.msg1.txt
187 # Sig generated by: perl aux-fixed/dkim/sign.pl --method=simple/simple --selector=ses \
188 #                       --keyfile=aux-fixed/dkim/dkim512.private < aux-fixed/4500.msg1.txt
189 client 127.0.0.1 PORT_D
190 ??? 220
191 HELO xxx
192 ??? 250
193 MAIL FROM:<CALLER@bloggs.com>
194 ??? 250
195 RCPT TO:<a@test.ex>
196 ??? 250
197 DATA
198 ??? 354
199 DKIM-Signature: v=1; a=rsa-sha1; c=simple/simple; d=test.ex; h=from:to
200         :date:message-id:subject; s=ses; bh=OB9dZVu7+5/ufs3TH9leIcEpXSo=; b=
201         cIErF1eueIT9AU4qG54FyT3yrlVDDM7RZnuU6fWTevZpAuMqhYcRO8tU3U4vtKWB
202         +I2vd+F1gzqCzBcRtfLhZg==
203 From: mrgus@text.ex
204 To: bakawolf@yahoo.com
205 Date: Thu, 19 Nov 2015 17:00:07 -0700
206 Message-ID: <qwerty1234@disco-zombie.net>
207 Subject: simple test
208
209 This is a simple test.
210 .
211 ??? 250
212 QUIT
213 ??? 221
214 ****
215 killdaemon
216 #
217 no_stdout_check
218 no_msglog_check