Skip to content

Master user


Master users allow administrative access to all mailboxes without knowing individual user passwords. This guide covers the configuration steps for different Dovecot versions.

  • Edit conf.d/auth-master.conf.ext file Master users support multiple authentication drivers including LDAP. This example will use passwd-file
Dovecot 2.3
passdb {
  driver = passwd-file
  master = yes
  args = /etc/dovecot/master-users
  result_success = continue
}
Dovecot 2.4 and later
passdb master-passwd-file {
  driver = passwd-file
  master = yes
  passwd_file_path = /etc/dovecot/master-user
  result_success = continue
}
  • Create file /etc/dovecot/master-user specified in configuration
master:{PLAIN}password
  • Disable user authentication bind in dovecot ldap configuration
auth_bind = no

WARNING: If you want to allow master users to log in by specifying the master username within the normal username string (ie. not using SASL mechanism's support for it), you can specify the separator character here. The format is then . UW-IMAP uses "*" as the separator, so that could be a good choice.

auth_master_user_separator = *
  • Enable master authentication in conf.d/10-auth.conf
!include auth-ldap.conf.ext
!include auth-master.conf.ext
  • Test authentication using master account
doveadm auth test "user*master" password