1 # Exim test configuration 5750 (dup of 5760)
2 # $tls_out_peercert - GnuTLS
8 host_lookup_order = bydns
9 primary_hostname = myhost.test.ex
10 rfc1413_query_timeout = 0s
11 spool_directory = DIR/spool
12 log_file_path = DIR/spool/log/SERVER%slog
14 gecos_name = CALLER_NAME
17 # ----- Main settings -----
19 acl_smtp_rcpt = accept
21 log_selector = +tls_peerdn
26 tls_advertise_hosts = *
28 tls_certificate = DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.pem
29 tls_privatekey = DIR/aux-fixed/exim-ca/example.com/server1.example.com/server1.example.com.unlocked.key
32 tls_verify_certificates = DIR/aux-fixed/exim-ca/example.com/server2.example.com/ca_chain.pem
34 event_action = ${acl {server_cert_log}}
41 accept condition = ${if eq {tls:cert}{$event_name}}
42 logwrite = [$sender_host_address] \
44 ${certextract{subject}{$tls_in_peercert}}
48 accept logwrite = $event_name depth=$event_data \
49 <${certextract {subject} {$tls_out_peercert}}>
53 warn logwrite = $acl_arg1 $local_part
54 warn logwrite = ${if !def:tls_out_ourcert \
55 {NO CLIENT CERT presented} \
56 {Our cert SN: ${certextract{subject}{$tls_out_ourcert}}}}
57 accept condition = ${if !def:tls_out_peercert}
58 logwrite = No Peer cert
59 accept logwrite = Peer cert:
60 logwrite = ver <${certextract {version} {$tls_out_peercert}}>
61 logwrite = SN <${certextract {subject} {$tls_out_peercert}}>
62 logwrite = SN; <${certextract {subject,>;} {$tls_out_peercert}}>
63 logwrite = SNCN<${certextract {subject,CN} {$tls_out_peercert}}>
64 logwrite = IN <${certextract {issuer} {$tls_out_peercert}}>
65 logwrite = NB <${certextract {notbefore} {$tls_out_peercert}}>
66 logwrite = NA <${certextract {notafter} {$tls_out_peercert}}>
67 logwrite = SA <${certextract {sig_algorithm} {$tls_out_peercert}}>
68 logwrite = SG <${certextract {signature} {$tls_out_peercert}}>
69 logwrite = ${certextract {subj_altname} {$tls_out_peercert}{SAN <$value>}{(no SAN)}}
70 # logwrite = ${certextract {ocsp_uri} {$tls_out_peercert} {OCU <$value>}{(no OCU)}}
71 logwrite = ${certextract {crl_uri} {$tls_out_peercert} {CRU <$value>}{(no CRU)}}
74 accept condition = ${if eq {msg} {${listextract{1}{$event_name}}}}
75 acl = ev_msg $event_name $acl_arg2
76 accept condition = ${if eq {tls} {${listextract{1}{$event_name}}}}
77 message = ${acl {ev_tls}}
86 condition = ${if eq {SERVER}{server}{no}{yes}}
88 transport = send_to_server
91 # ----- Transports -----
101 tls_certificate = DIR/aux-fixed/exim-ca/example.com/server2.example.com/server2.example.com.pem
102 tls_privatekey = DIR/aux-fixed/exim-ca/example.com/server2.example.com/server2.example.com.unlocked.key
104 tls_verify_certificates = DIR/aux-fixed/exim-ca/\
105 ${if eq {$local_part}{good}\
106 {example.com/server1.example.com/ca_chain.pem}\
107 {example.net/server1.example.net/ca_chain.pem}}
109 event_action = ${acl {logger} {$event_name} {$domain} }