122 lines
4.8 KiB
HTML
122 lines
4.8 KiB
HTML
<html>
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
|
<title>Mailbox sharing (Sharing IMAP folder with other users)</title>
|
|
<link href="./css/markdown.css" rel="stylesheet"></head>
|
|
</head>
|
|
<body>
|
|
|
|
<div id="navigation">
|
|
<a href="http://www.iredmail.org" target="_blank">iRedMail web site</a>
|
|
|
|
// <a href="./index.html">Document Index</a>
|
|
</div><h1 id="mailbox-sharing-sharing-imap-folder-with-other-users">Mailbox sharing (Sharing IMAP folder with other users)</h1>
|
|
<blockquote>
|
|
<p>Since iRedMail-<code>0.7.0</code>, mailbox sharing related settings are configured in
|
|
Dovecot but not enabled, what you need to do is enabling "acl" plugin as
|
|
mentioned below.</p>
|
|
<p>Since iRedMail-<code>0.9.0</code>, mailbox sharing are enabled by default, you don't need
|
|
to modify any config file.</p>
|
|
<p>Do not mistake "shared folders" for "public folders". For shared folders,
|
|
users must select which folder they want to share and with who, using an
|
|
interface, like IMAP command line or the ones available with Roundcube
|
|
webmail or SOGo and SOGo connectors.</p>
|
|
</blockquote>
|
|
<h2 id="enable-mailbox-sharing">Enable mailbox sharing</h2>
|
|
<p>To enable mailbox sharing, please make sure you have plugin <code>acl</code> enabled
|
|
in Dovecot config file <code>/etc/dovecot/dovecot.conf</code> like below:</p>
|
|
<ul>
|
|
<li>For Dovecot-1.2:</li>
|
|
</ul>
|
|
<pre><code># Part of file: /etc/dovecot/dovecot.conf
|
|
|
|
protocol lda {
|
|
mail_plugins = ... acl
|
|
}
|
|
|
|
protocol imap {
|
|
mail_plugins = ... acl imap_acl
|
|
}
|
|
</code></pre>
|
|
|
|
<ul>
|
|
<li>For Dovecot-2.x:</li>
|
|
</ul>
|
|
<pre><code># Part of file: /etc/dovecot/dovecot.conf
|
|
|
|
mail_plugins = ... acl
|
|
|
|
protocol imap {
|
|
mail_plugins = ... imap_acl
|
|
}
|
|
</code></pre>
|
|
|
|
<p>Restarting Dovecot service is required.</p>
|
|
<h2 id="test-shared-folder">Test shared folder</h2>
|
|
<p>Example: share from@domain.ltd's <code>Sent</code> folder to user <code>testing@domain.ltd</code>.</p>
|
|
<blockquote>
|
|
<p>WARNING: Do not forget the dot before IMAP command.</p>
|
|
</blockquote>
|
|
<pre><code># telnet localhost 143 # <- Type this.
|
|
* OK [...] Dovecot ready.
|
|
|
|
. login from@domain.ltd passwd # <- Type this.
|
|
# Login with full email address and password
|
|
. OK [... ACL ..] Logged in
|
|
|
|
. SETACL Sent testing@domain.ltd rli # <- Type this.
|
|
# Share folder `Sent` with user testing@domain.ltd,
|
|
# with permissions: read (r), lookup (l) and insert (i).
|
|
. OK Setacl complete.
|
|
|
|
^] # <- Press `Ctrl + ]` to exit telnet.
|
|
telnet> quit
|
|
</code></pre>
|
|
|
|
<p>Log into Roundcube webmail or SOGo as user <code>testing@domain.ltd</code>, you should
|
|
see the shared folder.</p>
|
|
<p>Some more details:</p>
|
|
<ul>
|
|
<li>
|
|
<p>After you shared folder with <code>SETACL</code> command, dovecot will insert a record
|
|
in MySQL database.</p>
|
|
<ul>
|
|
<li>With OpenLDAP backend, it's stored in <code>iredadmin.share_folder</code>.</li>
|
|
<li>With MySQL/MariaDB/PostgreSQL backends, it's stored in <code>vmail.share_folder</code>.</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<pre><code># mysql -uroot -p
|
|
mysql> USE vmail;
|
|
mysql> SELECT * FROM share_folder;
|
|
+-----------------+--------------------+-------+
|
|
| from_user | to_user | dummy |
|
|
+-----------------+--------------------+-------+
|
|
| from@domain.ltd | testing@domain.ltd | 1 |
|
|
+-----------------+--------------------+-------+
|
|
</code></pre>
|
|
|
|
<h2 id="references">References</h2>
|
|
<ul>
|
|
<li>
|
|
<p>Dovecot wiki:</p>
|
|
<ul>
|
|
<li><a href="http://wiki2.dovecot.org/SharedMailboxes/Shared">Mailbox sharing between users (v2.0+)</a></li>
|
|
<li><a href="http://wiki.dovecot.org/SharedMailboxes/Shared">Mailbox sharing between users (v1.2+)</a></li>
|
|
</ul>
|
|
</li>
|
|
<li>
|
|
<p>Roundcubemail has official plugin <code>acl</code> to manage mailbox sharing.</p>
|
|
</li>
|
|
<li>SOGo groupware supports mailbox sharing by default: right-click IMAP folder, choose <code>Sharing</code>.</li>
|
|
<li><a href="https://addons.mozilla.org/en-US/thunderbird/addon/imap-acl-extension/">Imap-ACL-Extension for Thunderbird</a>, manage acls/permissions for shared mailboxes/folders on imap servers.</li>
|
|
</ul><p style="text-align: center; color: grey;">Document published under a <a href="http://creativecommons.org/licenses/by-nd/3.0/us/" target="_blank">CC BY-ND 3.0</a> license. If you found something wrong, please do <a href="http://www.iredmail.org/contact.html">contact us</a> to fix it.<script>
|
|
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
|
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
|
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
|
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
|
|
|
ga('create', 'UA-3293801-21', 'auto');
|
|
ga('send', 'pageview');
|
|
</script>
|
|
</body></html> |