Hi list, I like to have public mailboxes in addition to other private in the same domain, and manage the public mailbox permissions through acls. For example: info at domain.com <- public, readable by user2 user1 at domain.com <- private user2 at domain.com <- private The mailboxes are virtual, authentication through pam (kerberos). The public mailbox doesn't have valid kerberos account. My smtp server is exim 4.80. I set the mail delivery to lmtp. I couldn't find solution in the documentation, how can I manage the email delivery to the public namespace? There is a -m option in the lda delivery where you can give namespace prefix. Maybe it's good for this, but I couldn't find any information how can I do this with lmtp? my dovecot config: test:~# dovecot -n # 2.1.7: /etc/dovecot/dovecot.conf # OS: Linux 3.0.0-1-686-pae i686 Debian squeeze/sid managesieve_notify_capability = mailto 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 namespace { location = sdbox:/home/vmail/public/%u prefix = public. separator = . subscriptions = no type = public } namespace inbox { inbox = yes location = sdbox:/home/vmail/private/%n mailbox Drafts { auto = subscribe special_use = \Drafts } mailbox Junk { special_use = \Junk } mailbox Sent { auto = subscribe special_use = \Sent } mailbox "Sent Messages" { special_use = \Sent } mailbox Spam { auto = subscribe special_use = \Junk } mailbox Trash { auto = subscribe special_use = \Trash } prefix separator = . } passdb { driver = pam } plugin { acl = vfile sieve = /home/vmail/%n/.dovecot.sieve sieve_dir = /home/vmail/%n sieve_global_dir = /home/vmail/sieve } protocols = " imap lmtp sieve" service managesieve-login { inet_listener sieve { port = 4190 } service_count = 1 } ssl_cert = </etc/dovecot/dovecot.pem ssl_key = </etc/dovecot/private/dovecot.pem userdb { args = uid=1035 gid=8 home=/home/vmail/%Lu allow_all_users=yes driver = static } protocol lmtp { mail_plugins = " sieve" } protocol lda { mail_plugins = " sieve" } protocol sieve { mail_max_userip_connections = 10 managesieve_implementation_string = Dovecot Pigeonhole managesieve_logout_format = bytes=%i/%o managesieve_max_line_length = 65536 } Best regards: L?szl? Kir?ly
* Laszlo Kiraly <l.kiraly at madalbal.hu> 2013.06.27 14:20:> I couldn't find solution in the documentation, how can I manage the email > delivery to the public namespace?[...]> namespace { > location = sdbox:/home/vmail/public/%u > prefix = public. > separator = . > subscriptions = no > type = public > }You can use sieve for that with LMTP: if address :is ["To","CC"] "someone at domain.tld" { fileinto "Public.Mailbox.Folder"; } I personally use / separators so not 100% the syntax applies to your scenario. Thomas -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 198 bytes Desc: Digital signature URL: <http://dovecot.org/pipermail/dovecot/attachments/20130628/bf7dd09d/attachment-0001.bin>
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Thu, 27 Jun 2013, Laszlo Kiraly wrote:> info at domain.com <- public, readable by user2 > user1 at domain.com <- private > user2 at domain.com <- private > > The mailboxes are virtual, authentication through pam (kerberos). > The public mailbox doesn't have valid kerberos account. > > I couldn't find solution in the documentation, how can I manage the email > delivery to the public namespace? > > There is a -m option in the lda delivery where you can give namespace prefix. > Maybe it's good for this, but I couldn't find any information how can I do > this with lmtp?If you set: lmtp_save_to_detail_mailbox = yes recipient_delimiter = # you could alias info at domain.com to <user>#Public.Mailbox.Folder at domain.com . 1st option tells LMTP to use the detail (subaddress) as default mailbox, which is essentially the same as the -m option of the LDA. 2nd options sets the delimiter of user and detail. <user> must habe write permission to the folder. Regards, - -- Steffen Kaiser -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) iQEVAwUBUdLHeV3r2wJMiz2NAQJp/Qf+JG6RYpMbgP9K+POoaP4mFHPNr2NXcLlK RhO7GtOimZpyQZPeofStxJQwY4clRdKpKsmpMlhb1muXyvoHkB6Tn5TDO18Anqlq /Yp8li53rsx4hVptqI84tiZrPiPX52U7FJmM/j95a+gFelTOgOPFwNoTaIIMAQau qn1rVa4BYIhMUQTP4WJDnj+gs8Fd1LapajBcVR0yaMGkWKRLKjsOrgFzDaxQqpxk 8erJnGV68p+wEl0jnWEF2+U8XubvhqHJTbkrcBC7DsqONBzlXC7mc+xyycb+0okD 54dHI6YcSLvzDEI3uaOqoBxad4e2fvziEgYJ7Ph78aH80psAWNmu3A==rJPs -----END PGP SIGNATURE-----