mirror of
https://github.com/opensolutions/ViMbAdmin.git
synced 2026-04-26 00:36:00 +03:00
[GH-ISSUE #277] Cannot create new Mailbox or set Password #227
Labels
No labels
bug
feature
feature
improvement
improvement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ViMbAdmin-opensolutions#227
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @huddx01 on GitHub (Feb 18, 2021).
Original GitHub issue: https://github.com/opensolutions/ViMbAdmin/issues/277
Hi,
I cannot create new Mailboxes or set another password for the mailboxes since i modified something in the config...
It seems that the "doeveadm pw" fails... but if i run it as root, it works...
Example:
/usr/bin/doveadm pw -s 'SHA512-CRYPT' -u 'xxx@mydomain.com' -p 'myPass12345678!' {SHA512-CRYPT}$6$oLZ5VcgQoAoYleSu$5B71l9rHAkjkVKyCDFbGAdu6OwkeyYlh00ukniQkwcWZFc3JN8.EqwdhwRC6J5u.NSSuTvVy8pJuLpOPyjIo61If i try it wit the www-data privileges, it fails:
runuser -u www-data -- /usr/bin/doveadm pw -s 'SHA512-CRYPT' -u -u 'xxx@mydomain.com' -p 'myPass12345678!' doveconf: Fatal: Error in configuration file /etc/dovecot/dovecot.conf line 144: ssl_cert: Can't open file /etc/letsencrypt/live/mydomain.com/fullchain.pem: Permission deniedI know it seems to be something with the access rights to the le - certificates... But other apache-vhosts have no problem accessing to it...
Maybe someone has a hint?
Thanks in advance!
@barryo commented on GitHub (Feb 19, 2021):
Hi @huddx01
This looks a bit awkward.
I take it you mean they have no issue accessing the LE certs for SSL? Which would be correct because Apache kicks off as root, accesses what it needs and drops to the
www-datauser then.My inclination would be to configure sudo to that your config becomes something like:
and your (for example)
/etc/sudoers.d/vimbadminmight have (untested, read the docs):@huddx01 commented on GitHub (Feb 19, 2021):
@barryo
Yes, there are ne issues with LE certs for SSL...
So, i completly renewed the Le Cert for the vimbadmin domain. After this, still didnt work...
But i followed your good Idea to add the www-data User into the sudoers for the doveadm command.
And it works now!
Ok - its a workaround for now. Thank you so far.
But something seems to be weird...
I will reinstall the vimbadmin stuff completely. Maybe in a few days...
@sdellenb commented on GitHub (Oct 23, 2021):
The problem is that doveadm loads the full dovecot configuration, but is unable to load the certificates specified, because they're (correctly) only accessible by root. They are not needed for doveadm functionality.
I tried overriding doveadm parameters with
-o ssl=no -o ssl_cert=''as per the man page, but they were ignored.A better solution would be to do this: https://github.com/postfixadmin/postfixadmin/issues/398#issuecomment-843124406
@mulderij commented on GitHub (Mar 6, 2022):
An alternative I use with postfixadmin is through php_crypt and then modify the Dovecot password query against MariaDB. This could be possible with ViMbAdmin
/etc/postfixadmin/config.local.php
/etc/dovecot/dovecot-sql.conf.ext
This doesn't add the the string for the encryption method in the database, but adds it in the result returned to Dovecot. For some unclear reason Dovecot needs this (the
\<code>should have been enough). Of course if you are only using sha512 not all rewrite cases are necessary, but they don't hurt...@barryo commented on GitHub (Apr 1, 2022):
Time out closing on this - please reopen if help still required.
@s-a-s-k-i-a commented on GitHub (Apr 17, 2023):
Is this fixed in vimbadmin 3.4.x?
As I am seeing this currently in my Vimbadmin 3.3.1 installation and I have not implemented any workaround yet.