c9337869d8b5669f161d16543f82ad7113ae2cf1
[exim.git] / test / stdout / 0002
1 >
2 > # These expansions can test variables in the configuration, but as there
3 > # is no message being processed, there is no message-related data. But
4 > # that of course gets tested in plenty of other places.
5 >
6 > # Some fixed variables
7 >
8 > exim_path: TESTSUITE/eximdir/exim
9 > exim_version: x.yz
10 > config_dir: TESTSUITE
11 > config_file: TESTSUITE/test-config
12 > primary_hostname: myhost.test.ex
13 > primary_hostname: myhost.test.ex
14 > qualify_domain: myhost.test.ex
15 > bounce_return_size_limit: 102400
16 > spool_directory: TESTSUITE/spool
17 > queue_name:
18 > Failed: unknown variable in "${unknown}"
19 > h_subject: (should be empty)
20 > h_subject: (should be empty)
21 > Failed: unknown expansion operator "header_subject"
22 >
23 > # $message_headers should be empty
24 > message_headers: ><
25 >
26 > # Continuation
27 > xy
28 > xy
29 >
30 > # Overlong names and overbig numbers
31 >
32 > Failed: unknown variable name "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
33 > Failed: unknown variable in "${aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa}"
34 > +
35 > +
36 >
37 > eval: 0
38 > eval: 1
39 > eval: -1
40 > eval: 1
41 > eval: 2
42 > eval: 7
43 > eval: 9
44 > eval: 4
45 > eval: 6
46 > eval: 42
47 > Failed: error in expression evaluation: expecting number or opening parenthesis (after processing "")
48 > eval: -2
49 > eval: 1
50 > eval: 1
51 > Failed: error in expression evaluation: expecting closing parenthesis (after processing "-2 - (-3")
52 > Failed: error in expression evaluation: expecting operator (after processing "-2 - -3")
53 > eval: 1
54 > eval: -5
55 > eval: 1
56 > eval: 40962
57 > eval: 63
58 > Failed: error in expression evaluation: expecting operator (after processing "0")
59 > eval10: 77
60 > eval10: 8
61 > Failed: error in expression evaluation: expecting operator (after processing "0")
62 > eval: 4
63 > eval: 4
64 > eval: 4
65 > eval: 13
66 > eval: 9
67 > eval: 6
68 > eval: 3
69 > eval: 0
70 > eval: 24
71 > eval: 4608
72 > eval: 4608
73 > eval: -4608
74 >
75 > # List operations
76 >
77 > filter: "a:b:c"
78 > filter: a:c
79 > filter: a'c
80 > filter: ''a' ''c
81 > filter: ""
82 >
83 > map: ""
84 > map: a:b:c
85 > map: ::a::: ::b::: ::c::
86 > map: fail string
87 > map: []:[b]:[c]
88 >
89 > reduce: "+"
90 > reduce: +abc
91 > reduce: 6
92 > reduce: 9
93 > # Check for extract corrupting reduce's
94 > reduce: a , b
95 >
96 > listnamed: *.aa.bb : ^\Nxxx(.*)
97 > listnamed: *.aa.bb : ^\Nxxx(.*)
98 > listnamed: V4NET.11.12.13 : iplsearch;TESTSUITE/aux-fixed/0002.iplsearch
99 > listnamed: *.aa.bb : ^\Nxxx(.*) : ;;
100 > listnamed: a : b;c : *.aa.bb : ^\Nxxx(.*) : ;; : 2001::630::212::8::204::::b664
101 > Failed: "nolist" is not a named list
102 > listnamed: *.aa.bb : ^\Nxxx(.*)
103 > Failed: "hlist" is not a domain named list
104 > Failed: bad suffix on "list" operator
105 >
106 > listcount: 3
107 > listcount: 0
108 > listcount: 3
109 > listcount: 2
110 >
111 > listextract: b
112 > listextract: XcX
113 > listextract:
114 > listextract:
115 > listextract: fail
116 > Failed: "listextract" failed and "fail" requested
117 >
118 > sort: 1:2:3:4
119 > sort: 4,3,2,1
120 > sort: a:aa:B:c
121 > sort: 10 smtp.ex.com:100 r2.ex.com:666 r99.ex.com
122 > sort: 10,smtp.ex.com:100,r2.ex.com:666,r99.ex.com
123 > sort: ""
124 >
125 > # Tests with iscntrl() and illegal separators
126 >
127 > map: 'a'
128 ''
129 'b'
130 'c'
131 >
132 > Failed: error in expression evaluation: expecting number or opening parenthesis (after processing "0+") inside "reduce" item
133 > reduce: 6
134 > reduce: 6
135 > reduce: 6
136 >
137 > # Operators
138 >
139 > Failed: Not enough arguments for 'acl' (min is 1)
140 > Failed: Not enough arguments for 'acl' (min is 1)
141 > Failed: error from acl "a_nosuch"
142 > acl: (0) [] []
143 > acl: (1) [person@dom.ain] []
144 > acl: (2) [firstarg] [secondarg]
145 > acl: (1) [arg with spaces] []
146 > acl:
147 > acl:
148 > acl: (0) [] []
149 > acl: (1) [person@dom.ain] []
150 > Failed: error from acl "a_defer"
151 > acl: (2) [new arg1] [top_arg_1]
152 > acl: (1) [1] [] (1) [2] [] (1) [3] [] (1) [4] []
153 >
154 > addrss: local-part@dom.ain
155 > addrss: local-part@dom.ain
156 > addrss: local-part@dom.ain
157 > addrss: local-part@dom.ain
158 > addrss: local-part@dom.ain
159 > addrss: local-part.dot-atom@dom.ain
160 > addrss: local-part@dom.ain
161 > domain: dom.ain
162 > domain: dom.ain
163 > domain: dom.ain
164 >
165 > addresses: ''abc@xyz' ''pqr@xyz
166 > addresses: local-part@dom.ain
167 > addresses: local-part@dom.ain+xyz@abc
168 > addresses: local-part@dom.ain:xyz@abc:p@q:r@s
169 > addresses:
170 > Failed: output separator missing in expanding ${addresses:>}
171 >
172 > escape: B7\267F2\362
173 > excape8bit: undisturbed text tab
174 newline tab\134backslash ~tilde\177DEL\200\201.
175 >
176 > expand: $primary_hostname myhost.test.ex
177 > hash: jmg monty fbWx
178 > hash: abcX abX aX X
179 > hex2b64:EjRWeA==
180 > hex2b64:q83v
181 > hex2b64:q83v
182 > hex2b64:Gis8TV5v
183 > Failed: "1a2b3c4d5e6" contains an odd number of characters
184 > Failed: "1a2b3c4d5e6g" is not a hex string
185 > hex2b64:MPPJPkZDbetYunCBao7BJA==
186 > hex2b64:ztcfpyNSMb7Tg/rP3EHE3cwi7PE=
187 >
188 > base32: 0 <>
189 > base32: 1 <b>
190 > base32: 31 <7>
191 > base32: 32 <ba>
192 > base32: 42 <bk>
193 > Failed: argument for base32 operator is "0x1", which is not a decimal number
194 >
195 > base32d: 0 0
196 > base32d: 1 1
197 > base32d: 31 31
198 > base32d: 32 32
199 > base32d: 42 42
200 > Failed: argument for base32d operator is "ABC", which is not a base 32 number
201 >
202 > the base62 operator is actually a base36 operator in the Darwin and Cygwin
203 > environments. Write cunning tests that produce the same output in both cases,
204 > while doing a reasonable check.
205 >
206 > base62: OK
207 > base62d: OK
208 > base62d: OK
209 > Failed: argument for base62 operator is "12345x", which is not a decimal number
210 > Failed: argument for base62d operator is "0003D7.", which is not a base 36/62 number
211 >
212 > hmac: dd97e3ba5d1a61b5006108f8c8252953
213 > hmac: 0210cf9d274b53f1550f657c378b29e8bfed1064
214 > md5: 77add1d5f41223d5582fca736a5cb335
215 > sha1: DA39A3EE5E6B4B0D3255BFEF95601890AFD80709
216 > sha1: A9993E364706816ABA3E25717850C26C9CD0D89D
217 > mask: 192.168.10.192/28
218 > mask: 192.168.10.206/32
219 > Failed: mask value too big in "192.168.10.206/33"
220 > mask: 0.0.0.0/0
221 > Failed: missing mask value in "192.168.10.206"
222 > Failed: "a.b.c.d" is not an IP address
223 > ipv6denorm: 0000:0000:0000:0000:0000:0000:0000:0001
224 > ipv6denorm: fe00:0000:0000:0000:0000:0000:0000:0001
225 > ipv6denorm: 0000:0000:0000:0000:0000:ffff:c0a8:0001
226 > ipv6denorm: fe80:0000:0000:0000:0000:0000:c0a8:0001
227 > ipv6norm: ::1
228 > ipv6norm: 2a00::
229 > ipv6norm: 2a00::1
230 > ipv6norm: 2a00:eadf::1:0
231 > ipv6norm: 2a00:eadf:0:1::
232 > ipv6norm: 2a00::
233 > ipv6norm: 2a00:2:3:4:5:6:7:8
234 > nhash: 19 0/61
235 > lc/uc: the quick BROWN FOX
236 > length: The quick abc
237 > lclpt: local-part
238 > lclpt: local-part
239 > lclpt: local.part
240 > quote: aZ09_.-Q "ab*cd" "abcd\"ef"
241 > quote: "nl(\n)"
242 > quote: "cr(\r)"
243 > quote: "tab( )"
244 > quote: "xff(ÿ)"
245 > quote: Empty>""<
246 > quote_local_part: abcd
247 > quote_local_part: O'Reilly
248 > quote_local_part: "a space"
249 > quote_local_part: ".something"
250 > quote_local_part: "something."
251 > quote_local_part: joe.bloggs
252 > quote_local_part: a!b
253 > quote_local_part: "x@y"
254 > quote_local_part: ab*cd
255 > quote_local_part: "x:y"
256 > quote_local_part: "abcd\"ef"
257 > quote_local_part: ""
258 > rxquote:aZ09\_\,\-Q ab\*cd abcd\"ef
259 > hexquote: \x01\x02\x03\x04\x05\x06\x07\x20\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f\x20\x10\x11\x12\x13\x14\x15\x16\x17\x20\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20\x20!"#$%&'\x20()*+,-./\x2001234567\x2089:;<=>?\x20@ABCDEFG\x20HIJKLMNO\x20PQRSTUVW\x20XYZ[\]^_\x20`abcdefg\x20hijklmno\x20pqrstuvw\x20xyz{|}~\x7f
260 > substr: ba 34 1
261 > substr: barb rhuba
262 > substr:
263 > substr:
264 > str2b64:YWJjZA==
265 > str2b64:VGhlIHF1aWNrIGJyb3duIAogZm94
266 > base64: YWJjZA==
267 > base64: VGhlIHF1aWNrIGJyb3duIAogZm94
268 > base64d:abcd
269 > base64d:The quick brown
270 fox
271 > strlen: 0
272 > strlen: 1
273 > strlen: 8
274 > time_eval: 10
275 > time_eval: 7200
276 > time_eval: 86700
277 > time_eval: 788645
278 > Failed: string "14" is not an Exim time interval in "time_eval" operator
279 > Failed: string "rhubarb" is not an Exim time interval in "time_eval" operator
280 > time_interval: 0s
281 > time_interval: 44s
282 > time_interval: 1w4d13h46m39s
283 > Failed: string "-1" is not a positive number in "time_interval" operator
284 > Failed: string "rhubarb" is not a positive number in "time_interval" operator
285 >
286 > # stat is a bit tricky, but some of the fields of the aux-var directory
287 > # should be the same on all systems
288 >
289 > stat: 40755
290 > stat: drwxr-xr-x
291 > Failed: stat(/a/non/existent/file) failed: No such file or directory
292 >
293 > # "Operators" that have expanded arguments
294 >
295 > hash: jmg monty fbWx
296 > hash: abcX abX aX X
297 > nhash: 19 0/61
298 > length: The quick abc
299 > substr: ba 34 1
300 > substr:
301 >
302 > # Error forms
303 >
304 > Failed: Not enough arguments for 'hash' (min is 2)
305 > Failed: "nonnumber" is not a number (in "hash" expansion)
306 > Failed: Too many arguments for 'hash' (max is 3)
307 > Failed: "-2" is not a positive number (in "substr" expansion)
308 >
309 > # Skipped operators
310 >
311 > addrss: NO
312 > domain: NO
313 > escape: NO
314 > expand: NO
315 > hash: NO
316 > md5: NO
317 > mask: NO
318 >
319 > # Number suffixes in conditions
320 > 1k: y
321 > 1K: y
322 > 1M: y
323 > 1G: y
324 >
325 > # Numeric overflow
326 > # >32b should work, >64b not
327 >
328 > 1 > 2047M n
329 > 1 > 2048M n
330 > 1 > 4096000000 n
331 > 1 > 4096M n
332 > 1 > 4611686018427387904 n
333 > Failed: absolute value of integer "46116860184273879040" is too large (overflow)
334 >
335 > # Conditions
336 >
337 > 2=2: y
338 > 2==2: y
339 > 3=2: n
340 > 2==3: n
341 > !2=2: n
342 > !2==2: n
343 > !3=2: y
344 > !2==3: y
345 > 2>3: n
346 > 3>3: n
347 > 4>3: y
348 > 1>-1: y
349 > 2>=3: n
350 > 3>=3: y
351 > 4>=3: y
352 > 2<3: y
353 > 3<3: n
354 > 4<3: n
355 > 2<=3: y
356 > 3<=3: y
357 > 4<=3: n
358 > 5<=3: n
359 > -3<=1: y
360 >
361 > 5>3k: n
362 > 5>3m: n
363 > Failed: invalid integer "3z "
364 > Failed: integer expected but "a" found
365 > Failed: integer expected but "${substr_2_2:65535}" found
366 >
367 > >0: n
368 > =: y
369 > -2<: y
370 > 08>07: y
371 > 011=11: y
372 >
373 > def:y y
374 > def:n n
375 > Failed: unknown variable "post" after "def:"
376 > def:h_f n
377 > def:h_f n
378 > Failed: curly-bracket problem in conditional yes/no parsing: 'yes' part did not start with '{'
379 remaining string is ':{y}{n}}'
380 >
381 > exists: y
382 > exists: n
383 >
384 > eq: y
385 > eq: n
386 > !eq: n
387 > !eq: y
388 >
389 > eqi: y
390 > eqi: y
391 > eqi: n
392 > !eqi: n
393 > !eqi: n
394 > !eqi: y
395 >
396 > lt: y
397 > lti: n
398 > le: y
399 > lei: y
400 > gt: n
401 > gti: n
402 > ge: n
403 > gei: y
404 >
405 > isip: y 1.2.3.4
406 > isip4: y 1.2.3.4
407 > isip6: n 1.2.3.4
408 > isip: n ::1.2.3.256
409 > isip4: n 1.2.3.256
410 > isip: n 1:2:3:4
411 > isip4: n 1:2:3:4
412 > isip6: n 1:2:3:4
413 > isip: y ::1
414 > isip4: n ::1
415 > isip6: y ::1
416 > isip: y fe80::a00:20ff:fe86:a061
417 > isip4: n fe80::a00:20ff:fe86:a061
418 > isip6: y fe80::a00:20ff:fe86:a061
419 > isip: y fe80::1.2.3.4
420 > isip: n rhubarb
421 > isip4: n rhubarb
422 > isip6: n rhubarb
423 >
424 > match: cdab
425 > match: cdab
426 > match: cdab
427 > Failed: "if" failed and "fail" requested
428 > match: cd[xyz]ab
429 >
430 > match_domain: yes
431 > match_domain: no
432 > match_domain: yes
433 > match_domain: yes
434 > match_domain: no
435 >
436 > >x@zz.aa.bb< [] >x@zz.aa.bb<
437 >
438 > >x@xxxabc< [] >x@xxxabc<
439 >
440 > match_address: yes
441 > match_address: yes
442 >
443 > match_local_part:yes
444 > match_local_part:yes
445 >
446 > match_ip: 01 true
447 > match_ip: 02
448 > match_ip: 03 true
449 > match_ip: 04 true
450 > match_ip: 05
451 > match_ip: 06
452 > match_ip: 07 true
453 > match_ip: 08 true
454 > match_ip: 09
455 > match_ip: 10 true
456 > Failed: "somename" is not an IP address
457 > match_ip: 12 true
458 > match_ip: 13 true
459 > match_ip: 14 true
460 > match_ip: 15 true
461 >
462 > queue_running: n
463 > first_delivery: n
464 >
465 > queue_running after or: y
466 > first_delivery after or: y
467 >
468 > # acl expansion condition
469 > acl if: Y:(0) [] []
470 > acl if: Y:(1) [argY] []
471 > acl if: N:(2) [argN] [arg2]
472 > Failed: error from acl "a_defer"
473 >
474 > # Default values for both if strings
475 >
476 > ${if eq{1}{1}} >true<
477 > ${if eq{1}{2}} ><
478 >
479 > # Lookups: DIR is the testing directory. In this test we can only use the
480 > # lookups that are required in all cases.
481 >
482 > CALLER
483 >
484 > ==X@Y
485 > ==*
486 > ==*@Z
487 > ==*
488 >
489 > data for a.b.c.d
490 > failed x.y.z
491 > data for *.p.q
492 > data for *.p.q
493 > data for *.p.q
494 > Failed: "lookup" failed and "fail" requested
495 > data for *
496 >
497 > q1: "abc"
498 > q2: "xyz":
499 > q3: "pqr" :
500 > q4: "a:b" abc continued data (make sure not key)
501 > q5: "\"quoted\""
502 > q6: "white space"
503 > q7: "b\\s"
504 >
505 > abc: abc
506 > a.b.c: *.b.c
507 > ab.c: *b.c
508 > xyz: ^X
509 > .Xyz: ^X
510 > .Zyz: ^Z
511 > a b: "^a +b"
512 > a b: "^a +b"
513 > a:b: lookup succeeded
514 > a.b: ^a\\.+b
515 > a..b: ^a\\.+b
516 > a9b: \N^a\d+b
517 > a99b: \N^a\d+b
518 >
519 > # Should give the same results as above because expansion does nothing
520 >
521 > abc: abc
522 > a.b.c: *.b.c
523 > ab.c: *b.c
524 > xyz: ^X
525 > .Xyz: ^X
526 > .Zyz: ^Z
527 > a b: "^a +b"
528 > a b: "^a +b"
529 > a:b: lookup succeeded
530 >
531 > # Should fail because of no expansion
532 >
533 > a.b: NO
534 > a..b: NO
535 > a9b: NO
536 > a99b: NO
537 >
538 > # But these should succeed
539 >
540 > a\:b: ^a\\.+b
541 > a\:Xb: ^a\\.+b
542 >
543 > # Some tests of case-(in)dependence
544 >
545 > .MiXeD-CD: Data found for case-dependent MiXeD-CD
546 > .MixeD-CD: NOT FOUND
547 > .MiXeD-Ncd: Data found for case-independent MiXeD-nCD
548 > .MixeD-Ncd: Data found for case-independent MiXeD-nCD
549 >
550 > # IP address (CIDR) lookups
551 >
552 > 1.2.3.4: data for 1.2.3.4
553 > 1.2.3.5:
554 > 1.2.3.5: data for *
555 > abcd::cdab: data for abcd::cdab
556 > 192.168.1.2: data for 192.168.0.0/16
557 > 192.168.5.6: data for 192.168.0.0/16
558 > abcd:abcd:: data for abcd:abcd::/32
559 > abcd:abcd:1:: data for abcd:abcd::/32
560 > abcd:abcd::3 data for abcd:abcd::/32
561 > Failed: lookup of "rhubarb" gave DEFER: "rhubarb" is not a valid iplsearch key (an IP address, with optional CIDR mask, is wanted): in a host list, use net-iplsearch as the search type
562 >
563 >
564 > # Nested Lookups - style 1
565 >
566 > The data for key1->key2
567 > Failed: "lookup" failed and "fail" requested
568 >
569 > # Nested Lookups - style 2
570 >
571 > The data for key1->key2
572 > failed for key4
573 >
574 > # Other nesting tests
575 >
576 > 1-in-1
577 > 2-in-2
578 > both-in-1,both-in-2
579 > Failed: "lookup" failed and "fail" requested
580 >
581 > # Lookup quotes for standardly expected lookups
582 >
583 > lsearch !@#$%^&*()_-+=|\~`1234567890{[}]qwertyuiop:;"'asdfghjkl<,>.?/zxcvbnm
584 > Failed: unknown lookup type "xxx"
585 >
586 > # Extract
587 >
588 > 2
589 > 2
590 > 2
591 > 2
592 > empty:<>
593 > empty:<>
594 > <3>
595 > <3>
596 > empty:<>
597 > empty:<>
598 > no Z
599 > no 4
600 > Failed: "extract" failed and "fail" requested
601 > Failed: "extract" failed and "fail" requested
602 > D
603 > a:b:c:d:e
604 > a
605 > e
606 > a
607 > FAIL
608 > b
609 >
610 > b
611 > three four
612 > Failed: first argument of "extract" must not be empty
613 > Failed: first argument of "extract" must not be empty
614 > b
615 >
616 > a:b:c
617 > Failed: missing '}' closing extract inside "map" item
618 > a:b:c
619 >
620 > # Translation
621 >
622 > abcdea aaa xyz zbcdez
623 > abcdea a z zbcdez
624 > abcdea a abcdea
625 > abcdea abc z zzzdez
626 >
627 > # Boolean
628 > "TrUe" true EXPECT: true
629 > "FALSE" false EXPECT: false
630 > " yes" true EXPECT: true
631 > " no" false EXPECT: false
632 > "yes " true EXPECT: true
633 > "-1" true EXPECT: true
634 > "0" false EXPECT: false
635 > "1" true EXPECT: true
636 > " 0 " false EXPECT: false
637 > " 1 " true EXPECT: true
638 > "1111111111111111111" true EXPECT: true
639 > "9" true EXPECT: true
640 > " " false EXPECT: false
641 > Failed: unrecognised boolean value "text"
642 > Failed: unrecognised boolean value "text"
643 > Failed: unrecognised boolean value "-text"
644 > Failed: unrecognised boolean value "text"
645 > Failed: unrecognised boolean value "text"
646 > "00" false EXPECT: false
647 > "!true" false EXPECT: false
648 > "!false" true EXPECT: true
649 >
650 > "TrUe" true EXPECT: true
651 > "FALSE" false EXPECT: false
652 > " yes" true EXPECT: true
653 > " no" false EXPECT: false
654 > "yes " true EXPECT: true
655 > "-1" true EXPECT: true
656 > "0" false EXPECT: false
657 > "1" true EXPECT: true
658 > " 0 " false EXPECT: false
659 > " 1 " true EXPECT: true
660 > "1111111111111111111" true EXPECT: true
661 > "9" true EXPECT: true
662 > " " false EXPECT: false
663 > "text" true EXPECT: true
664 > " text" true EXPECT: true
665 > "text " true EXPECT: true
666 > " text " true EXPECT: true
667 > "00" true EXPECT: true
668 > "!true" false EXPECT: false
669 > "!false" true EXPECT: true
670 >
671 > # RFC 2047
672 >
673 > abcd abcd
674 > <:abcd:> =?iso-8859-8?Q?=3C=3Aabcd=3A=3E?=
675 > <:ab cd:> =?iso-8859-8?Q?=3C=3Aab_cd=3A=3E?=
676 > long: =?iso-8859-8?Q?_here_we_go=3A_a_string_that_is_going_to_be_encoded=3A_?= =?iso-8859-8?Q?it_will_go_over_the_75-char_limit?=
677 > long: =?iso-8859-8?Q?_here_we_go=3A_a_string_that_is_going_to_be_encoded=3A_?= =?iso-8859-8?Q?it_will_go_over_the_75-char_limit_by_a_long_way=3B_in?= =?iso-8859-8?Q?_fact_this_one_will_go_over_the_150_character_limit?=
678 >
679 > # RFC 2047 decode
680 >
681 > abcd abcd
682 > <:abcd:> <:abcd:>
683 > <:ab cd:> <:ab cd:>
684 > Long: here we go: a string that is going to be encoded: it will go over the 75-char limit
685 > Long: here we go: a string that is going to be encoded: it will go over the 75-char limit by a long way; in fact this one will go over the 150 character limit
686 >
687 > # UTF-8
688 >
689 > abcd abcd
690 > aÀÿd aÀÿd
691 > toobig a_d
692 >
693 > # Substitution
694 >
695 > ${sg{abcdefabcdef}{abc}{xyz}} =xyzdefxyzdef
696 > ${sg{ab:xy::z}{:}{::}} =ab::xy::::z
697 > ${sg{abcdefabcdef}{(..)[^c]}{>$1<}} =a><><><ef
698 > ${sg{abcdefabcdef}{(..)[^c]}{>\$1<}} =a>bc<>ef<>bc<ef
699 > ${sg{abcdefabcdef}{(..)[^c]}{>\N$1\N<}}=a>bc<>ef<>bc<ef
700 > ${sg{abbab}{a*}{+}} =++b+b++b+
701 >
702 > # File insertion
703 >
704 > Failed: Not enough arguments for 'readfile' (min is 1)
705 > abcde
706 12345
707
708 xyz
709
710 > abcde12345xyz
711 > abcde:12345::xyz:
712 > abcde - 12345 - - xyz -
713 > Failed: failed to open /non/exist/file: No such file or directory
714 > non-exist
715 > >abcde!12345!!xyz!<
716 >
717 > # Calling a command
718 >
719 > abcd
720 1234
721
722 > rc=0
723 > 1
724 > rc=0
725 > abcd
726 1234
727
728 > rc=0
729 > 2
730 > rc=1
731 > abcd
732 1234
733
734 > rc=1
735 > N
736 > rc=127
737 > >><<
738 > rc=0
739 > 1!=2
740 > rc=0
741 >
742 > # PRVS
743 >
744 > prvs=xxxxxxxxxx=userx@test.ex
745 > prvs=xxxxxxxxxx=userx@test.ex
746 > prvs=xxxxxxxxxx=userx@test.ex
747 >
748 > # Syntax errors
749 >
750 > Failed: prvs third argument must be a single digit
751 > Failed: prvs third argument must be a single digit
752 > Failed: prvs third argument must be a single digit
753 >
754 > # Correct checks; can't put explicit addresses in the tests, because they
755 > # will change over time.
756 >
757 > userx@test.ex
758 > result=1
759 >
760 > >1< >userx@test.ex< >1<
761 > result=1
762 >
763 > userx@test.ex
764 > result=1
765 >
766 > # Incorrect secret
767 >
768 > userx@test.ex
769 > result=
770 >
771 > 0
772 > result=
773 >
774 > # Non-prvs address
775 >
776 > >><<
777 > result=
778 >
779 > # Syntax errors
780 >
781 > Failed: "${tod_log" is not a known operator (or a } is missing in a variable reference)
782 > Failed: "${tod_log" is not a known operator (or a } is missing in a variable reference)
783 > Failed: missing } at end of string
784 > Failed: missing } at end of string
785 > Failed: hmac algorithm "xxx" is not recognised
786 > Failed: each subcondition inside an "and{...}" condition must be in its own {}
787 > Failed: unknown condition "xya" inside "and{...}" condition
788 > Failed: condition name expected, but found "${lookup{x}lsear" inside "and{...}" condition
789 > Failed: missing } at end of string - could be header name not terminated by colon
790 > Failed: curly-bracket problem in conditional yes/no parsing: did not close with '}'
791 remaining string is ''
792 > Failed: missing or misplaced { or } - could be header name not terminated by colon
793 > Failed: each subcondition inside an "or{...}" condition must be in its own {}
794 > Failed: missing } at end of condition inside "or" group
795 > Failed: unknown condition "yes" inside "or{...}" condition
796 > Failed: non-digit after underscore in "substr_1_"
797 > Failed: non-digit after underscore in "substr__3"
798 >
799 > # Iterations: forany and forall
800 >
801 > yes
802 > yes
803 > yes
804 > no
805 > yes
806 > no
807 > no
808 > yes
809 > yes
810 >
811 > Failed: unknown condition "yes" inside "forany" condition
812 > Failed: missing } at end of condition inside "forany"
813 >
814 > yes
815 > no
816 > no
817 > no
818 >
819 > no
820 > yes
821 > yes
822 > yes
823 >
824 > # Expect yes
825 > outer=yes item='' (unset)
826 >
827 > # Expect no
828 > outer=no
829 >
830 > # Error inside nest - check message is helpful
831 > Failed: missing } at end of condition inside "forall" inside "forany" condition
832 >
833 >
834 > # Miscellaneous (for bug fixes, etc)
835 >
836 > true
837 >
838 > # Environment access
839 >
840 > CALLER
841 > correct
842 >
843 > # JSON
844 >
845 > "http://www.example.com/image/481989943"
846 > 100
847 > 943
848 > 943
849 >
850 > "green"
851 > green
852 > <>
853 > expect: <>
854 >
855 > 59
856 > 59
857 >
858 > {"1":116, "2":943, "3":234}
859 > expect: {"1":116, "2":943, "3":234}
860 >
861 > {"1":116, "2":943, "3":234}
862 > expect: {"1":116, "2":943, "3":234}
863 >
864 > <>
865 > expect: <>
866 > <>
867 > expect: <>
868 >
869 > yes
870 > yes
871 >
872 >
873 > escape: B7·F2ò
874 >
875 > primary_hostname: myhost.test.ex
876 > match: cdab
877 > Failed: "if" failed and "fail" requested
878 > yes
879 > match_address: no
880 >
881 > primary_hostname: myhost.test.ex
882 > match: cdab
883 > Failed: "if" failed and "fail" requested
884 > yes
885 > match_address: no
886 >
887 > -be Sender host name and address etc, all unset
888 > -oMa sender_host_address =
889 > sender_host_port = 0
890 > -oMaa sender_host_authenticated =
891 > -oMai authenticated_id = CALLER
892 > -oMas authenticated_sender = CALLER@myhost.test.ex
893 > -oMi interface_address =
894 > interface_port = -1
895 > -oMr received_protocol =
896 > -oMs sender_host_name =
897 > -oMt sender_ident = CALLER
898 >
899 > -be Sender host name and address etc, all set except host name.
900 > -oMa sender_host_address = V4NET.0.0.1
901 > sender_host_port = 1234
902 > -oMaa sender_host_authenticated = AAA
903 > -oMai authenticated_id = philip
904 > -oMas authenticated_sender = xx@yy.zz
905 > -oMi interface_address = 1.1.1.1
906 > interface_port = 99
907 > -oMr received_protocol = special
908 > -oMt sender_ident = me
909 >
910 > -be Sender host name explicitly set
911 > -oMa sender_host_address = V4NET.0.0.1
912 > sender_host_port = 1234
913 > -oMs sender_host_name = my.host.name
914 >
915 > be Sender host name lookup fails (V4NET.11.12.13 is not reverse registered)
916 > -oMs sender_host_name =
917 > host_lookup_failed = 1
918 >
919 > -be Sender host name and protocol set by Sendmail-compatible option
920 > -p received_protocol = special
921 > -p sender_host_name = host.name
922 >
923 > -be Sender host name and address etc, all set except host name
924 > -oMa sender_host_address = V4NET.0.0.1
925 > sender_host_port = 1234
926 > -oMaa sender_host_authenticated = AAA
927 > -oMai authenticated_id = philip
928 > -oMas authenticated_sender = xx@yy.zz
929 > -oMi interface_address = 1.1.1.1
930 > interface_port = 99
931 > -oMr received_protocol = special
932 > ----> No lookup yet: No
933 > -oMs sender_host_name = ten-1.test.ex
934 > -oMt sender_ident = me
935 >
936
937 **** SMTP testing session as if from host V4NET.0.0.1
938 **** but without any ident (RFC 1413) callback.
939 **** This is not for real!
940
941 550 Administrative prohibition
942
943 **** SMTP testing session as if from host V4NET.0.0.2
944 **** but without any ident (RFC 1413) callback.
945 **** This is not for real!
946
947 550 Administrative prohibition
948
949 **** SMTP testing session as if from host V4NET.0.0.0
950 **** but without any ident (RFC 1413) callback.
951 **** This is not for real!
952
953 220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
954 250 OK
955 250 Accepted
956 354 Enter message, ending with "." on a line by itself
957 550 reply_address=<>
958 250 OK
959 250 Accepted
960 354 Enter message, ending with "." on a line by itself
961 550 reply_address=<a@b>
962 250 OK
963 250 Accepted
964 354 Enter message, ending with "." on a line by itself
965 550 reply_address=<c@d>
966 250 OK
967 250 Accepted
968 354 Enter message, ending with "." on a line by itself
969 550 reply_address=<>
970 250 OK
971 250 Accepted
972 354 Enter message, ending with "." on a line by itself
973 550 reply_address=<x@y>
974 221 myhost.test.ex closing connection
975
976 **** SMTP testing session as if from host V4NET.0.0.0
977 **** but without any ident (RFC 1413) callback.
978 **** This is not for real!
979
980 220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
981 250 OK
982 250 Accepted
983 354 Enter message, ending with "." on a line by itself
984 550 reply_address=<>
985 221 myhost.test.ex closing connection
986
987 **** SMTP testing session as if from host V4NET.0.0.0
988 **** but without any ident (RFC 1413) callback.
989 **** This is not for real!
990
991 220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
992 250 OK
993 250 Accepted
994 354 Enter message, ending with "." on a line by itself
995 550 reply_address=<>
996 221 myhost.test.ex closing connection
997 > match_ip: 15
998 > match_ip: 16
999 >
1000 > in list
1001 > in list
1002 >