Add expansion variable $headers_added returning newline-sep list of headers
[exim.git] / test / confs / 0567
1 # Exim test configuration 0532
2
3 CONNECTCOND=
4
5 exim_path = EXIM_PATH
6 host_lookup_order = bydns
7 primary_hostname = myhost.test.ex
8 rfc1413_query_timeout = 0s
9 spool_directory = DIR/spool
10 log_file_path = DIR/spool/log/%slog
11 gecos_pattern = ""
12 gecos_name = CALLER_NAME
13
14 # ----- Main settings -----
15
16 acl_smtp_connect = connect
17 acl_smtp_mail = mail
18 acl_smtp_rcpt = rcpt
19 acl_smtp_predata = predata
20 acl_smtp_data = data
21 acl_not_smtp = notsmtp
22
23 qualify_domain = test.ex
24 trusted_users = CALLER
25
26 hostlist internal_headers = x-mail-2 : x-mail-3
27
28
29 # ----- ACL -----
30
31 begin acl
32
33 connect:
34 accept CONNECTCOND
35
36 mail:
37 accept remove_header = x-mail-1
38 senders = mailok@test.ex
39 # Won't work because doesn't expand
40 remove_header = +internal_headers
41 accept
42
43 rcpt:
44 accept local_parts = rcptok
45 remove_header = x-rcpt-4 : x-rcpt-2
46 set acl_m_hdr = x-predata-1
47 deny add_header = RCPT: denied $local_part
48
49
50 predata:
51 warn remove_header = x-predata-3 : $acl_m_hdr
52 # Won't work because doesn't use wildcards
53 accept remove_header = x-not-*
54
55 data:
56 warn log_message = Verified previously removed header X-Rcpt-2
57 condition = ${if eq{$h_x-rcpt-2:}{}}
58 warn remove_header = x-data-1 : x-data-4
59 condition = ${if eq{$h_cond:}{accept}}
60 remove_header = x-data-3
61 # Won't delete this header because condition fails before the modifier
62 warn condition = ${if eq{$h_cond:}{reject}}
63 remove_header = x-data-2
64 warn log_message = Verified removed header X-Data-3 in this ACL still visible
65 condition = ${if !eq{$h_x-data-3:}{}}
66 accept
67
68 notsmtp:
69 # Will remove a required header (Date) if told to
70 accept remove_header = x-notsmtp-1 : date
71
72
73 # ----- Routers -----
74
75 begin routers
76
77 r1:
78 driver = accept
79 transport = t1
80
81
82 # ----- Transports -----
83
84 begin transports
85
86 t1:
87 driver = appendfile
88 file = DIR/test-mail/$local_part
89 user = CALLER
90
91 # End