summaryrefslogtreecommitdiff
path: root/test/confs/5711
blob: 2c6af3cf24e1d0f61866d15f8447defb3511767f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Exim test configuration 5711

.include DIR/aux-var/tls_conf_prefix

primary_hostname = myhost.test.ex

# ----- Main settings -----

acl_smtp_connect = check_conn
acl_smtp_quit =    accept logwrite = ACL quit
acl_smtp_notquit = accept logwrite = ACL notquit

tls_advertise_hosts = *
tls_certificate = DIR/aux-fixed/cert1

host_reject_connection = ${acl {hrc}}
smtp_banner = ${if != {$received_port}{PORT_D4} {my banner}fail}
event_action = ${acl {tls_fail}}

log_selector = +pid

# ------ ACL ------

begin acl

hrc:
  warn		logwrite = eval host_reject_connection
  accept	condition = ${if eq {$received_port}{PORT_D}}
		# no mesage= hence host_reject_connection should be empty
  deny		condition = ${if eq {$received_port}{PORT_D2}}
		message = *
                # PORT_D2 gets a host_reject_connection

check_conn:
  warn		logwrite =	ACL conn
  deny		condition =	${if eq {$received_port}{PORT_D3}}
		log_message =	we dislike you
		# PORT_D3 gets a conn ACL fail
  accept

tls_fail:
  warn		logwrite =  EV $event_name
  accept	condition = ${if eq {tls:fail:connect}{$event_name}}
		logwrite =  EVDATA: $event_data
  accept


# End