pmg-smtp-filter runs with root?

May 10, 2023
Hi Proxmox,

first thanks for the nice product.
While testing, I discovered that the process /usr/bin/pmg-smtp-filter runs with root rights. To my unterstand this process do all the filtering on the mail, is it really necessary to run it with root? Sure it's a pearl script, but e.g. a simple wrong call to an archiver could exploit the whole system when running with root rights, as happened to Barracuda Email Security Gateway.

bye Josef
that's a good question, but the answer is not so easy i'm afraid:

pmg-smtp-filter has to access many things (the db, config files, etc.)
we'd have to check if that would all be possible without root (at least for the db we'd have to configure some access rules/users which don't exist currently)
(i don't know every access off the top of my head, i'd first have to look)

for now it's not as simple as changing the running user, but i agree that having a different user for that would be a good idea (if possible)

would you mind opening a feature request/bug for that on ?


The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!