<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Why running dovecot as root?]]></title><description><![CDATA[<p dir="auto">Hello, I wonder if dovecot has to be running as root?</p>
<pre><code># ps aufx | grep root
root      152591  0.0  0.0   2888  1040 pts/0    Ss   10:47   0:00 /bin/sh
root      152599  0.0  0.0   7204  2912 pts/0    R+   10:47   0:00  \_ ps aufx
root      152600  0.0  0.0   3468  1556 pts/0    S+   10:47   0:00  \_ grep root
root           1  0.0  0.0  34460  3536 ?        Ss   Sep25   8:02 /usr/bin/python3 /usr/bin/supervisord --configuration /etc/supervisor/supervisord.conf --nodaemon -i Mail
root          64  0.0  0.0   8284  1300 ?        S    Sep25   1:09 /usr/sbin/dovecot -c /run/dovecot.conf -F
root          75  0.0  0.0   4932   828 ?        S    Sep25   0:22  \_ dovecot/log
root          76  0.0  0.0   7684  2344 ?        S    Sep25   2:17  \_ dovecot/config
</code></pre>
<p dir="auto">I can't seem to find any requirement for that. From what I'm aware off, Docker won't work as an efficient isolation mechanism, if root privileges obtained inside Docker container.</p>
<p dir="auto">Please, correct me if I'm wrong!</p>
]]></description><link>https://forum.cloudron.io/topic/12662/why-running-dovecot-as-root</link><generator>RSS for Node</generator><lastBuildDate>Sat, 13 Jun 2026 12:43:47 GMT</lastBuildDate><atom:link href="https://forum.cloudron.io/topic/12662.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 18 Oct 2024 10:53:16 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Why running dovecot as root? on Tue, 29 Oct 2024 16:48:59 GMT]]></title><description><![CDATA[<p dir="auto">For anyone wondering on the same question as I did: Dovecot seems to be a standard IMAP server for now, which seems to be used on majority of servers. It <a href="https://www.dovecot.org/security/" target="_blank" rel="noopener noreferrer nofollow ugc">claims</a> to be written with security in mind, which doesn't seem to help to avoid privileges escalations, buffer overflow, crashes (on the same page - below).</p>
<p dir="auto">Given the dominance of that mail server on the internet, it seems to be a go-to solution for many, just like Ubuntu, referred here above, is; so I wouldn't expect it to be replaced on Cloudron anytime soon.</p>
<p dir="auto">Given the self-confidence of the authors, that claims that running from root is not a big deal and not providing any easily ready to use solution, I doubt that many will go extra mile to implement that on they own; given Cloudron limited resources and luck of advertising and hence focus to be security first platform, dovecot processes will remain to be running as root.</p>
<p dir="auto">From the positive side, root owned processes are not opening any network port, so direct exploitation would be problematic.</p>
<p dir="auto">Hope that would be of help.</p>
]]></description><link>https://forum.cloudron.io/post/96198</link><guid isPermaLink="true">https://forum.cloudron.io/post/96198</guid><dc:creator><![CDATA[potemkin_ai]]></dc:creator><pubDate>Tue, 29 Oct 2024 16:48:59 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 14:53:38 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/nebulon" aria-label="Profile: nebulon">@<bdi>nebulon</bdi></a> said in <a href="/post/95899">Why running dovecot as root?</a>:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/necrevistonnezr" aria-label="Profile: necrevistonnezr">@<bdi>necrevistonnezr</bdi></a> this may be more of a case of slightly different priorities and taste, servers running software (and exposed to the internet) are never 100% secure, so hardening is always a bit of an ongoing process which can be as detailed as one wants. We try to strike some balance on Cloudron side, to keep things maintainable and updatable also.</p>
</blockquote>
<p dir="auto">Thanks again - that makes perfect sense.<br />
If I may ask - did you consider other alternatives? If so - what did you rejected and why? Would you choose Dovecot again now?</p>
<p dir="auto">Feel free to ignore my questions - that's definitely outside of the scope of the platform, would appreciate if you could share some piece of wisdom thought!</p>
]]></description><link>https://forum.cloudron.io/post/95905</link><guid isPermaLink="true">https://forum.cloudron.io/post/95905</guid><dc:creator><![CDATA[potemkin_ai]]></dc:creator><pubDate>Mon, 21 Oct 2024 14:53:38 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 14:52:21 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/necrevistonnezr" aria-label="Profile: necrevistonnezr">@<bdi>necrevistonnezr</bdi></a> said in <a href="/post/95898">Why running dovecot as root?</a>:</p>
<blockquote>
<p dir="auto">But anyway, this is tiring. Checking out.</p>
</blockquote>
<p dir="auto">Can't recall I've been begging you to join and participate in the discussion... In case if I did, sure - don't hesitate to explore things around - it's so much better without some kind of knowledge (and it's not a joke).</p>
]]></description><link>https://forum.cloudron.io/post/95904</link><guid isPermaLink="true">https://forum.cloudron.io/post/95904</guid><dc:creator><![CDATA[potemkin_ai]]></dc:creator><pubDate>Mon, 21 Oct 2024 14:52:21 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 11:44:53 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/necrevistonnezr" aria-label="Profile: necrevistonnezr">@<bdi>necrevistonnezr</bdi></a> this may be more of a case of slightly different priorities and taste, servers running software (and exposed to the internet) are never 100% secure, so hardening is always a bit of an ongoing process which can be as detailed as one wants. We try to strike some balance on Cloudron side, to keep things maintainable and updatable also.</p>
]]></description><link>https://forum.cloudron.io/post/95899</link><guid isPermaLink="true">https://forum.cloudron.io/post/95899</guid><dc:creator><![CDATA[nebulon]]></dc:creator><pubDate>Mon, 21 Oct 2024 11:44:53 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 11:39:51 GMT]]></title><description><![CDATA[<p dir="auto">It's interesting that you're now suggesting that neither the maintainer of Dovecot, nor the maintainer of Ubuntu, nor the maintainer of Cloudron have the capacity or interest of "hardening" their product.<br />
And, BTW, without giving any substantiation why this would improve security other than "root should be avoided in general". But anyway, this is tiring. Checking out.</p>
]]></description><link>https://forum.cloudron.io/post/95898</link><guid isPermaLink="true">https://forum.cloudron.io/post/95898</guid><dc:creator><![CDATA[necrevistonnezr]]></dc:creator><pubDate>Mon, 21 Oct 2024 11:39:51 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 11:34:00 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/necrevistonnezr" aria-label="Profile: necrevistonnezr">@<bdi>necrevistonnezr</bdi></a> , it seems like you miss the fact that Dovecot created instruction afterwards.<br />
Another thing is that if the product of your choice doesn't support best or just good enough security practices - it might be worth to change the product.</p>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/nebulon" aria-label="Profile: nebulon">@<bdi>nebulon</bdi></a> , got it, it's a pity. I would rather have all processes in Docker (including nginx) running as non-root.<br />
But probably it's a subject for another project 'Hardened Cloudron', that doesn't seem to be in high demand, so from the product perspective I understand your choice - thanks for letting me know it!</p>
]]></description><link>https://forum.cloudron.io/post/95897</link><guid isPermaLink="true">https://forum.cloudron.io/post/95897</guid><dc:creator><![CDATA[potemkin_ai]]></dc:creator><pubDate>Mon, 21 Oct 2024 11:34:00 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 11:28:14 GMT]]></title><description><![CDATA[<p dir="auto">So given that the upstream project mostly sees the non-root instructions for local development and not as security improvments, we usually trust the upstream project decisions here, they know their code and especially dovecot is a battletested project anyways. So there is likely more risk for us to misconfigure it causing other side-effects than we gain from that.</p>
]]></description><link>https://forum.cloudron.io/post/95896</link><guid isPermaLink="true">https://forum.cloudron.io/post/95896</guid><dc:creator><![CDATA[nebulon]]></dc:creator><pubDate>Mon, 21 Oct 2024 11:28:14 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 11:26:10 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/girish" aria-label="Profile: girish">@<bdi>girish</bdi></a> said in <a href="/post/95794">Why running dovecot as root?</a>:</p>
<blockquote>
<p dir="auto">I recall trying to run it as normal user but it's not worth it. It wants to access many different users (the mailbox user, the dovecot user, then permissions to intercommunicate between processes etc). So, we decided to go with what the distro guys (ubuntu) decided for us.</p>
</blockquote>
]]></description><link>https://forum.cloudron.io/post/95895</link><guid isPermaLink="true">https://forum.cloudron.io/post/95895</guid><dc:creator><![CDATA[necrevistonnezr]]></dc:creator><pubDate>Mon, 21 Oct 2024 11:26:10 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 11:24:07 GMT]]></title><description><![CDATA[<p dir="auto">The thing is that there is a guide to run dovecot not as root...</p>
]]></description><link>https://forum.cloudron.io/post/95894</link><guid isPermaLink="true">https://forum.cloudron.io/post/95894</guid><dc:creator><![CDATA[potemkin_ai]]></dc:creator><pubDate>Mon, 21 Oct 2024 11:24:07 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 11:22:11 GMT]]></title><description><![CDATA[<p dir="auto">No, I'm sure you missed nothing to overcome the "self-posed mindset limit".<br />
I just assumed that the design decisions of the Dovecot maintainers themselves, major distributions like Ubuntu or projects like <a href="https://community.mailcow.email/d/59-mailcow-containers-running-as-root" target="_blank" rel="noopener noreferrer nofollow ugc">Mailcow</a> - as well as the explanation by girish ("dovecot automatically steps down permissions") would be sensible - but maybe that's my limited mindset.</p>
]]></description><link>https://forum.cloudron.io/post/95893</link><guid isPermaLink="true">https://forum.cloudron.io/post/95893</guid><dc:creator><![CDATA[necrevistonnezr]]></dc:creator><pubDate>Mon, 21 Oct 2024 11:22:11 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 10:06:37 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/necrevistonnezr" aria-label="Profile: necrevistonnezr">@<bdi>necrevistonnezr</bdi></a> it seems like I've covered every one of your points in my messages earlier - please, let me know if you feel like I missed something.</p>
]]></description><link>https://forum.cloudron.io/post/95891</link><guid isPermaLink="true">https://forum.cloudron.io/post/95891</guid><dc:creator><![CDATA[potemkin_ai]]></dc:creator><pubDate>Mon, 21 Oct 2024 10:06:37 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 09:23:01 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/potemkin_ai" aria-label="Profile: potemkin_ai">@<bdi>potemkin_ai</bdi></a><br />
Well, on ubuntu, it's packaged like that, <a class="plugin-mentions-user plugin-mentions-a" href="/user/girish" aria-label="Profile: girish">@<bdi>girish</bdi></a> explained that it steps down permissions as needed, but sure, if there's a better way to do it...</p>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/girish" aria-label="Profile: girish">@<bdi>girish</bdi></a> said in <a href="/post/95794">Why running dovecot as root?</a>:</p>
<blockquote>
<p dir="auto">I think dovecot wants to be run as root. See first line in <a href="https://doc.dovecot.org/2.3/admin_manual/running_dovecot/" target="_blank" rel="noopener noreferrer nofollow ugc">https://doc.dovecot.org/2.3/admin_manual/running_dovecot/</a> . On ubuntu, it's packaged as such as well (/usr/sbin/dovecot) . dovecot automatically steps down permissions as needed. It's a complex program having many binaries. You will also see other programs run as dovecot user with ps aux output.</p>
</blockquote>
]]></description><link>https://forum.cloudron.io/post/95888</link><guid isPermaLink="true">https://forum.cloudron.io/post/95888</guid><dc:creator><![CDATA[necrevistonnezr]]></dc:creator><pubDate>Mon, 21 Oct 2024 09:23:01 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Mon, 21 Oct 2024 09:20:25 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/necrevistonnezr" aria-label="Profile: necrevistonnezr">@<bdi>necrevistonnezr</bdi></a> yeah, I addressed that earlier:</p>
<blockquote>
<p dir="auto">There is something doesn't add up for me in they way of thinking. For me - a good security rule - it's to minimize attack surface, since you can never know. That is the approach of OpenBSD system, for example. Separate, minimize exposure, etc.</p>
</blockquote>
<p dir="auto">For me the quote you mentioned only speaks about self-posed mindset limit.</p>
<p dir="auto">It's like saying that you don't need airbags on the car, as usually people doesn't get in the car crash, and if they would - a seatbelt would be sufficient.</p>
]]></description><link>https://forum.cloudron.io/post/95887</link><guid isPermaLink="true">https://forum.cloudron.io/post/95887</guid><dc:creator><![CDATA[potemkin_ai]]></dc:creator><pubDate>Mon, 21 Oct 2024 09:20:25 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Sun, 20 Oct 2024 13:12:49 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/potemkin_ai" aria-label="Profile: potemkin_ai">@<bdi>potemkin_ai</bdi></a> From your link (emphasis added)</p>
<blockquote>
<p dir="auto">It’s <strong>possible</strong> to make Dovecot run under a single system user without requiring root privileges at any point. <strong>This shouldn’t be thought of as a security feature</strong>, but instead simply as a way for non-admins to run Dovecot in their favorite mail server.</p>
</blockquote>
]]></description><link>https://forum.cloudron.io/post/95856</link><guid isPermaLink="true">https://forum.cloudron.io/post/95856</guid><dc:creator><![CDATA[necrevistonnezr]]></dc:creator><pubDate>Sun, 20 Oct 2024 13:12:49 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Fri, 18 Oct 2024 19:32:39 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/girish" aria-label="Profile: girish">@<bdi>girish</bdi></a> from the link above I can see:</p>
<blockquote>
<p dir="auto">Dovecot <strong>can</strong> simply be started by running dovecot as root.</p>
</blockquote>
<p dir="auto"><code>can != must</code> for me.</p>
<p dir="auto">There is something doesn't add up for me in they way of thinking. For me - a good security rule - it's to minimize attack surface, since you can never know. That is the approach of OpenBSD system, for example. Separate, minimize exposure, etc.</p>
<p dir="auto">Dovecot has a guide on how to run in non-root: <a href="https://doc.dovecot.org/2.3/configuration_manual/howto/rootless/" target="_blank" rel="noopener noreferrer nofollow ugc">https://doc.dovecot.org/2.3/configuration_manual/howto/rootless/</a></p>
<p dir="auto">At the begging they give very strange comment about a necessity to choose between chroot-ed and non-chroot-ed environment, while giving permissions to chroot without root in the section to follow.</p>
<p dir="auto">Anyway - do you believe the manual from that link could be of any help?</p>
<p dir="auto">Even on official Docker docs (<a href="https://www.docker.com/blog/understanding-the-docker-user-instruction/" target="_blank" rel="noopener noreferrer nofollow ugc">for example</a>) says:</p>
<blockquote>
<p dir="auto">Docker will run commands as the root user, which can pose <strong>significant security risks</strong>.</p>
</blockquote>
]]></description><link>https://forum.cloudron.io/post/95801</link><guid isPermaLink="true">https://forum.cloudron.io/post/95801</guid><dc:creator><![CDATA[potemkin_ai]]></dc:creator><pubDate>Fri, 18 Oct 2024 19:32:39 GMT</pubDate></item><item><title><![CDATA[Reply to Why running dovecot as root? on Fri, 18 Oct 2024 16:05:43 GMT]]></title><description><![CDATA[<p dir="auto">I think dovecot wants to be run as root. See first line in <a href="https://doc.dovecot.org/2.3/admin_manual/running_dovecot/" target="_blank" rel="noopener noreferrer nofollow ugc">https://doc.dovecot.org/2.3/admin_manual/running_dovecot/</a> .  On ubuntu, it's packaged as such as well (/usr/sbin/dovecot) . dovecot automatically steps down permissions as needed. It's a complex program having many binaries. You will also see other programs run as <code>dovecot</code> user with <code>ps aux</code> output.</p>
<p dir="auto">I recall trying to run it as normal user but it's not worth it. It wants to access many different users (the mailbox user, the dovecot user, then permissions to intercommunicate between processes etc). So, we decided to go with what the distro guys (ubuntu) decided for us.</p>
]]></description><link>https://forum.cloudron.io/post/95794</link><guid isPermaLink="true">https://forum.cloudron.io/post/95794</guid><dc:creator><![CDATA[girish]]></dc:creator><pubDate>Fri, 18 Oct 2024 16:05:43 GMT</pubDate></item></channel></rss>