Ajout : dovecot-antispam + amavis + crm114.
[lhc/ateliers.git] / etc / dovecot / dovecot.conf.m4
1 auth_mechanisms = plain
2 auth_ssl_require_client_cert = no
3 # NOTE: ne marche pas avec l'auth SASL depuis postfix qui ne fournit pas de certificat utilisateurice
4 auth_ssl_username_from_cert = yes
5 auth_verbose = yes
6 auth_debug = yes
7 disable_plaintext_auth = yes
8 first_valid_uid = 1000
9 lda_mailbox_autocreate = no
10 lda_mailbox_autosubscribe = yes
11 listen = *
12 log_timestamp = "%Y-%m-%d %H:%M:%S "
13 local_name imap.LOCAL_DOMAINNAME {
14 ssl_ca = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/crt+crl.self-signed.pem
15 ssl_cert = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/crt+crl.self-signed.pem
16 ssl_key = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/key.pem
17 }
18 local_name imap.cyclocoop.org {
19 ssl_ca = </etc/dovecot/cyclocoop.org/imap/x509/crt+crl.self-signed.pem
20 ssl_cert = </etc/dovecot/cyclocoop.org/imap/x509/crt+crl.self-signed.pem
21 ssl_key = </etc/dovecot/cyclocoop.org/imap/x509/key.pem
22 }
23 mail_debug = yes
24 mail_home = /home/mail/data/%d/%n
25 mail_location = maildir:/home/mail/data/%d/%n/Maildir:INDEX=/var/lib/dovecot-index/%d/%n:CONTROL=/var/lib/dovecot-control/%d/%n
26 # NOTE: INDEX et CONTROL sont sur une partition sans quota comme le demande la doc
27 # VOIR: http://wiki2.dovecot.org/Quota/FS
28 namespace inbox {
29 inbox = yes
30 location =
31 mailbox Drafts {
32 special_use = \Drafts
33 }
34 mailbox Junk {
35 special_use = \Junk
36 }
37 mailbox Sent {
38 special_use = \Sent
39 }
40 mailbox "Sent Messages" {
41 special_use = \Sent
42 }
43 mailbox Trash {
44 special_use = \Trash
45 }
46 prefix =
47 separator = +
48 }
49 namespace {
50 #list = children
51 list = yes
52 location = maildir:/home/mail/data/%%d/%%n/Maildir:INDEX=/var/lib/dovecot-index/%d/%n/Shared/%%n:CONTROL=/var/lib/dovecot-control/%d/%n/Shared/%%n
53 prefix = Partages+%%n+
54 separator = +
55 subscriptions = yes
56 type = shared
57 }
58 mail_plugins = $mail_plugins acl quota
59 #mail_privileged_group = mail
60 #mail_access_groups = mail
61 passdb {
62 args = scheme=plain username_format=%n /etc/dovecot/%d/passwd
63 driver = passwd-file
64 }
65 plugin {
66 acl = vfile:/etc/dovecot/acl/global.d
67 acl_anyone = allow
68 acl_shared_dict = file:/home/mail/acl/%d/shared.db
69 #antispam_allow_append_to_spam = yes
70 # NOTE: pour offlineimap
71 antispam_backend = pipe
72 #antispam_crm_args = -u;/home/mail/data/%d/.crm114;/usr/share/crm114/mailfilter.crm
73 antispam_crm_args = -u;/home/mail/crm114;/usr/share/crm114/mailfilter.crm
74 antispam_crm_binary = /usr/bin/crm
75 antispam_debug_target = syslog
76 #antispam_crm_env = HOME=%h;USER=%u
77 antispam_ham_keywords = NonJunk
78 antispam_pipe_program = /usr/bin/crm
79 antispam_pipe_program_args = -u;/home/mail/crm114;/usr/share/crm114/mailfilter.crm;--stats_only;--force
80 antispam_pipe_program_notspam_arg = --learnnonspam
81 antispam_pipe_program_spam_arg = --learnspam
82 antispam_pipe_program_unlearn_spam_args = --unlearn;--learnspam
83 antispam_pipe_program_unlearn_notspam_args = --unlearn;--learnnonspam
84 antispam_pipe_tmpdir = /home/mail/crm114/tmp
85 antispam_signature = X-CRM114-CacheID
86 antispam_signature_missing = move
87 antispam_spam = Junk
88 antispam_spam_keywords = Junk
89 antispam_trash = Trash
90 antispam_unsure = Unsure
91 antispam_verbose_debug = 0
92 quota = fs:user
93 recipient_delimiter = +
94 sieve = /home/mail/data/%d/%n/sieve
95 sieve_after = /etc/dovecot/sieve/after.d/
96 sieve_before = /etc/dovecot/sieve/before.d/
97 sieve_dir = /home/mail/data/%d/%n/sieve.d/
98 #sieve_extensions = +spamtest +spamtestplus
99 sieve_global_dir = /etc/dovecot/sieve/global.d/
100 sieve_max_script_size = 1M
101 sieve_quota_max_scripts = 0
102 sieve_quota_max_storage = 10M
103 sieve_spamtest_max_value = 10
104 sieve_spamtest_status_header = X-Spam-Score
105 sieve_spamtest_status_type = strlen
106 sieve_user_log = /home/mail/log/%d/sieve.%n.log
107 }
108 protocol imap {
109 mail_plugins = $mail_plugins antispam imap_acl imap_quota
110 }
111 service imap-login {
112 inet_listener imap {
113 address = 127.0.0.1
114 port = 143
115 ssl = no
116 }
117 inet_listener imaps {
118 port = 993
119 ssl = yes
120 }
121 }
122 protocol lda {
123 auth_socket_path = /var/run/dovecot/auth-userdb
124 hostname = LOCAL_DOMAINNAME
125 info_log_path =
126 log_path =
127 mail_plugins = $mail_plugins sieve
128 postmaster_address = postmaster+dovecot+lda@LOCAL_DOMAINNAME
129 syslog_facility = mail
130 }
131 protocol lmtp {
132 postmaster_address = postmaster+dovecot+lmtp@LOCAL_DOMAINNAME
133 mail_plugins = $mail_plugins sieve
134 #info_log_path = /tmp/dovecot-lmtp.log
135 }
136 protocol pop3 {
137 }
138 protocol sieve {
139 mail_debug = yes
140 #mail_max_userip_connections = 10
141 #managesieve_implementation_string = Dovecot Pigeonhole
142 managesieve_max_compile_errors = 5
143 #managesieve_max_line_length = 65536
144 #managesieve_notify_capability = mailto
145 #managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave
146 }
147 protocols = imap lmtp pop3 sieve
148 service lmtp {
149 #executable = lmtp -L
150 process_min_avail = 2
151 unix_listener /var/spool/postfix/private/dovecot-lmtp {
152 user = postfix
153 group = postfix
154 mode = 0600
155 }
156 #user = mail
157 }
158 service auth {
159 user = root
160 unix_listener auth-userdb {
161 user = dovecot
162 group = root
163 mode = 0666
164 }
165 unix_listener /var/spool/postfix/private/auth {
166 user = postfix
167 group = postfix
168 mode = 0660
169 }
170 }
171 service imap {
172 #vsz_limit =
173 # NOTE: most of the memory goes to mmap()ing files.
174 # You may need to increase this limit if you have huge mailboxes.
175 process_limit = 1024
176 }
177 service pop3 {
178 process_limit = 1024
179 }
180 ssl = required
181 ssl_ca = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/crt+crl.self-signed.pem
182 ssl_cert = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/crt+crl.self-signed.pem
183 ssl_cipher_list = ALL:!LOW:!SSLv2:!EXP:!aNULL
184 ssl_key = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/key.pem
185 ssl_verify_client_cert = yes
186 userdb {
187 driver = prefetch
188 }
189 userdb {
190 # NOTE: this userdb is only used by lda.
191 args = username_format=%n /etc/dovecot/%d/passwd
192 driver = passwd-file
193 }
194 verbose_ssl = no
195
196 # vim: ft=sh