Bug 1280433 - Default setting of first_valid_uid = 500 conflicts with system users
Default setting of first_valid_uid = 500 conflicts with system users
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: dovecot (Show other bugs)
7.1
All Linux
medium Severity medium
: rc
: ---
Assigned To: Michal Hlavinka
qe-baseos-daemons
Maxim Svistunov
: EasyFix
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-11-11 12:47 EST by Robert Scheck
Modified: 2016-11-04 03:22 EDT (History)
6 users (show)

See Also:
Fixed In Version: dovecot-2.2.10-7.el7
Doc Type: Known Issue
Doc Text:
The default value of `first_valid_uid` in *dovecot* has changed In Red Hat Enterprise Linux 7, the default configuration of `first_valid_uid` in *dovecot* was changed to `1000` to match the system wide configuration specified as `UID_MIN` in the `/etc/login.defs` file. If a system has `UID_MIN` manually changed to `500` and is relying on *dovecot* default value, *dovecot* will not serve users with IDs lower than `first_valid_uid`. As a consequence, if you have regular users with id less than `1000`, you have to update `first_valid_uid`. After you do this, *dovecot* will work as expected.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-11-04 03:22:50 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Robert Scheck 2015-11-11 12:47:07 EST
Description of problem:
Default setting of first_valid_uid conflicts with system users: The default
as per /etc/dovecot/conf.d/10-mail.conf is 500 while real system users are
also above UID 500, because the regular users at RHEL start at UID 1000. So
this is leading to the following errors by default:

$ doveadm purge -A
doveadm(polkitd): Error: user polkitd: Initialization failed: Namespace '': mkdir(/home/polkitd/mailboxes) failed: Permission denied (euid=999(polkitd) egid=997(polkitd) missing +w perm: /home, dir owned by 0:0 mode=0755)
doveadm(polkitd): Error: User init failed
doveadm(dovenull): Error: user dovenull: Initialization failed: Namespace '': mkdir(/home/dovenull/mailboxes) failed: Permission denied (euid=998(dovenull) egid=996(dovenull) missing +w perm: /home, dir owned by 0:0 mode=0755)
doveadm(dovenull): Error: User init failed
doveadm(unbound): Error: user unbound: Initialization failed: Namespace '': mkdir(/home/unbound/mailboxes) failed: Permission denied (euid=997(unbound) egid=995(unbound) missing +w perm: /home, dir owned by 0:0 mode=0755)
doveadm(unbound): Error: User init failed
doveadm(saslauth): Error: user saslauth: Initialization failed: Namespace '': mkdir(/home/saslauth/mailboxes) failed: Permission denied (euid=996(saslauth) egid=76(saslauth) missing +w perm: /home, dir owned by 0:0 mode=0755)
doveadm(saslauth): Error: User init failed
doveadm(nfsnobody): Error: user nfsnobody: Initialization failed: Namespace '': mkdir(/home/nfsnobody/mailboxes) failed: Permission denied (euid=65534(nfsnobody) egid=65534(nfsnobody) missing +w perm: /home, dir owned by 0:0 mode=0755)
doveadm(nfsnobody): Error: User init failed
$ 

Version-Release number of selected component (if applicable):
dovecot-2.2.10-4.el7_0.1.x86_64

How reproducible:
Everytime, see above and below.

Actual results:
Default setting of first_valid_uid = 500 conflicts with system users.

Expected results:
Change default from 500 to 1000 to avoid conflicts with system users.
Comment 1 Robert Scheck 2015-11-11 13:00:58 EST
Note, the userdb is passwd - I am not aware that there already a restriction
would be possible.
Comment 3 Robert Scheck 2015-11-11 13:10:54 EST
Cross-filed case 01538032 on the Red Hat customer portal.
Comment 6 Frantisek Sumsal 2016-07-19 06:26:00 EDT
Verified on RHEL-7.3 Beta with dovecot-2.2.10-7.el7.

Value of first_valid_uid in dovecot's config file is now 1000 (instead of 500).
Comment 8 errata-xmlrpc 2016-11-04 03:22:50 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-2477.html

Note You need to log in before you can comment on or make changes to this bug.