Use compressed form of ipv6 in $sender_host_address under -bh. Bug 3027
[exim.git] / test / confs / 3400
1 # Exim test configuration 3400
2
3 .include DIR/aux-var/std_conf_prefix
4
5 primary_hostname = myhost.test.ex
6
7 # ----- Main settings -----
8
9 domainlist local_domains = test.ex : *.test.ex
10
11 hostlist auth_hosts = 10.0.0.1
12 hostlist relay_hosts = 10.0.0.4
13 hostlist auth_relay_hosts = 10.0.0.3 : 10.0.0.4
14
15 acl_smtp_connect = check_connect
16 acl_smtp_etrn = check_etrn
17 acl_smtp_expn = check_expn
18 acl_smtp_rcpt = check_recipient
19 acl_smtp_vrfy = check_vrfy
20 auth_advertise_hosts = +auth_hosts : !+relay_hosts : +auth_relay_hosts : \
21                        10.0.0.5
22 smtp_accept_max_nonmail = 20
23 system_filter = DIR/aux-fixed/TESTNUM.filter
24 trusted_users = CALLER
25
26
27 # ----- ACL -----
28
29 begin acl
30
31 check_connect:
32   warn     hosts = 10.0.0.6
33            control = allow_auth_unadvertised
34   accept
35
36 check_recipient:
37   warn     hosts = 10.0.0.5
38            message = authentication-failed: $authentication_failed
39   accept   hosts = 10.0.0.5
40   accept   hosts = :
41   deny     hosts = +auth_hosts
42            message = authentication required
43           !authenticated = *
44   accept   domains = +local_domains
45   accept   hosts = +relay_hosts
46   accept   hosts = +auth_relay_hosts
47            endpass
48            message = authentication required
49            authenticated = *
50   deny     message = relay not permitted
51
52 check_etrn:
53   deny     hosts = +auth_hosts
54            message = authentication required
55           !authenticated = *
56   require  hosts = 10.0.0.0/24
57   warn     log_message = accepted ETRN $smtp_command_argument
58   accept
59
60 check_expn:
61   deny     hosts = +auth_hosts
62            message = authentication required
63           !authenticated = *
64   accept   hosts = 10.0.0.0/24
65
66 check_vrfy:
67   deny     hosts = +auth_hosts
68            message = authentication required
69           !authenticated = *
70   accept
71
72
73 # ----- Authentication -----
74
75 begin authenticators
76
77 mylogin:
78   driver = plaintext
79   public_name = mylogin
80   server_debug_print = +++MYLOGIN \$1="$1" \$2=\"$2" \$3="$3"
81   server_condition = "\
82     ${if match{$1}{^(\\\\S+)\\\\s+(\\\\S+)\\$}\
83     {${if and {{eq{$1}{userx}}{eq{$2}{secret}}}{yes}{no}}}{no}}"
84
85 plain:
86   driver = plaintext
87   public_name = PLAIN
88   server_condition = "\
89     ${if and {{eq{$auth2}{userx}}{eq{$auth3}{secret}}}{yes}{no}}"
90   server_set_id = $auth2
91
92 extended_plain:
93   driver = plaintext
94   public_name = EXPLAIN
95   server_prompts = :
96   server_condition = "\
97     ${if and {{eq{$auth2}{userx}}{eq{$auth3}{secret}}}{yes}{no}}"
98   server_set_id = $auth2
99
100 expanded_prompt_plain:
101   driver = plaintext
102   public_name = EXPANDED
103   server_prompts = $primary_hostname
104   server_condition = "\
105     ${if and {{eq{$auth2}{userx}}{eq{$auth3}{secret}}}{yes}{no}}"
106   server_set_id = $auth2
107
108 expanded_prompt_plain_fail:
109   driver = plaintext
110   public_name = EXPANDFAIL
111   server_prompts = $nonexistent
112   server_condition = "\
113     ${if and {{eq{$auth2}{userx}}{eq{$auth3}{secret}}}{yes}{no}}"
114   server_set_id = $auth2
115
116 defer:
117   driver = plaintext
118   public_name = DEFER
119   server_condition = "account suspended"
120   server_set_id = $auth2
121
122 login:
123   driver = plaintext
124   public_name = LOGIN
125   server_prompts = "User Name : Password "
126   server_condition = "\
127     ${if and {{eq{$auth1}{userx}}{eq{$auth2}{secret}}}{yes}{no}}"
128   server_set_id = $auth1
129
130
131 # ----- Routers -----
132
133 begin routers
134
135 fail_remote_domains:
136   driver = redirect
137   domains = ! +local_domains
138   data = :fail: unrouteable mail domain "$domain"
139
140 localuser:
141   driver = accept
142   local_parts = userx
143   transport = appendfile
144
145
146 # ----- Transports -----
147
148 begin transports
149
150 appendfile:
151   driver = appendfile
152   delivery_date_add
153   envelope_to_add
154   file = DIR/test-mail/$local_part
155   create_file = DIR/test-mail
156   return_path_add
157   user = CALLER
158
159
160 # End