Squashed commit of PIPE_CONNECT
[exim.git] / test / scripts / 4050-pipe-conn / 4052
CommitLineData
ee8b8090
JH
1# pipelined-connect, cache invalidation
2#
3#
4# Not attempted without a cache entry
5exim -bd -DSERVER=server -DCONNECTCOND=* -oX PORT_D
6****
7#
8exim nocache@test.ex
9Subject test 1
10
11****
12exim -DCONTROL=127.0.0.1 -q
13****
14exim -DNOTDAEMON -DSERVER=server -q
15****
16#
17#
18#
19# Go for it. This one should do early-pipelinng.
20exim hascache@test.ex
21Subject test 2
22
23****
24exim -DCONTROL=127.0.0.1 -q
25****
26exim -DNOTDAEMON -DSERVER=server -q
27****
28#
29#
30# Check that client doesn't try when the cache entry is too old
31# It will however create a new entry
32sleep 2
33#
34exim client_old@test.ex
35Subject test 3
36
37****
38exim -DRETRY=1s -DCONTROL=127.0.0.1 -q
39****
40exim -DNOTDAEMON -DSERVER=server -q
41****
42#
43killdaemon
44#
45#
46#
47sudo rm DIR/spool/db/misc
48#
49# Check that the cache is invalidated on SMTP errors from the server for the banner
50#
51server PORT_D 3
52>220 banner
53<EHLO
54>250-esmtp-resp
55>250-PIPELINING
56>250-X_PIPE_CONNECT
57>250 ok
58<MAIL
59>250 mail-from accepted
60<RCPT
61>250 rcpt-to accepted
62<DATA
63>354 data go-ahead
64.
65>250 message accepted
66<QUIT
67>220 bye
68*eof
69>220 banner
70<EHLO
71>250-esmtp-resp
72>250-PIPELINING
73>250-X_PIPE_CONNECT
74>250 ok
75<MAIL
76>250 mail-from accepted
77<RCPT
78>250 rcpt-to accepted
79<DATA
80>354 data go-ahead
81.
82>250 message accepted
83<QUIT
84>220 bye
85*eof
86*sleep 2
87<EHLO
88<MAIL
89<RCPT
90<DATA
91>450 sorry no banner for you today
92>550 sync error
93>550 sync error
94>550 sync error
95>550 sync error
96<QUIT
97>>220 bye
98*eof
99****
100exim -DCONTROL=127.0.0.1 -odi nocache2@test.ex withcache2@test.ex badbanner@test.ex
101body 2
102****
103#
104# Check that the cache is not invalidated on SMTP errors from the server after early-pipelining
105#
106server PORT_D 6
107>220 banner
108<EHLO
109>250-esmtp-resp
110>250-PIPELINING
111>250-X_PIPE_CONNECT
112>250 ok
113<MAIL
114>250 mail-from accepted
115<RCPT
116>250 rcpt-to accepted
117<DATA
118>354 data go-ahead
119.
120>250 message accepted
121<QUIT
122>220 bye
123*eof
124>220 banner
125<EHLO
126>250-esmtp-resp
127>250-PIPELINING
128>250-X_PIPE_CONNECT
129>250 ok
130<MAIL
131>250 mail-from accepted
132<RCPT
133>250 rcpt-to accepted
134<DATA
135>354 data go-ahead
136.
137>250 message accepted
138<QUIT
139>220 bye
140*eof
141*sleep 2
142<EHLO
143<MAIL
144<RCPT
145<DATA
146>220 banner
147>250-esmtp-resp
148>250-PIPELINING
149>250-X_PIPE_CONNECT
150>250 ok
151>250 mail good
152>250 rcpt good
153>550 obscure data error
154<QUIT
155>>220 bye
156*eof
157*sleep 2
158<EHLO
159<MAIL
160<RCPT
161<DATA
162>220 banner
163>250-esmtp-resp
164>250-PIPELINING
165>250-X_PIPE_CONNECT
166>250 ok
167>250 mail good
168>550 rcpt refused
169>550 data cmd rejected - no valid recipient
170<QUIT
171>>220 bye
172*eof
173*sleep 2
174<EHLO
175<MAIL
176<RCPT
177<DATA
178>220 banner
179>250-esmtp-resp
180>250-PIPELINING
181>250-X_PIPE_CONNECT
182>250 ok
183>550 mail cmd refused
184>550 rcpt cmd rejected - no valid mail
185>550 data cmd rejected - no valid mail
186<QUIT
187>>220 bye
188*eof
189*sleep 2
190>220 banner
191<EHLO
192>250-esmtp-resp
193>250-PIPELINING
194>250-X_PIPE_CONNECT
195>250 ok
196<MAIL
197>250 mail-from accepted
198<RCPT
199>250 rcpt-to accepted
200<DATA
201>354 data go-ahead
202.
203>250 message accepted
204<QUIT
205>220 bye
206*eof
207****
208exim -DCONTROL=127.0.0.1 -odi nocache@test.ex withcache@test.ex baddata@test.ex badrcpt@test.ex badmail@test.ex withcache2@test.ex
209body
210****
211#
212#
213# Check that the cache is updated on a change of advertised extensions
214# The conn will be made pipelined anyway (because we don't find out early)
215# but it's the DB dump that matters. Unfortunately the dump doesn't show
216# us the (binary) record content, only the key. So you need to look at the
217# debug output after all.
218server PORT_D 1
219>220 banner
220<EHLO
221>250-esmtp-resp
222>250-PIPELINING
223>250-X_PIPE_CONNECT
224>250-STARTTLS
225>250 ok
226<MAIL
227>250 mail-from accepted
228<RCPT
229>250 rcpt-to accepted
230<DATA
231>354 data go-ahead
232.
233>250 message accepted
234<QUIT
235>220 bye
236*eof
237****
238exim -d-all+transport -DCONTROL=127.0.0.1 -odi extchange@test.ex
239body
240****
241dump misc
242#
243no_msglog_check