Confined user mapped to SELinux sysadm_u, cannot run newaliases even after sudo'ing
Issue
-
When a user is running as SELinux role sysadm_r, it's not possible to update
/etc/aliases.dbby runningnewaliases.$ id -Z staff_u:staff_r:staff_t:s0-s0:c0.c1023 $ sudo id -Z staff_u:sysadm_r:sysadm_t:s0-s0:c0.c1023 $ sudo newaliases postalias: fatal: open /etc/aliases.db: Permission denied
Environment
- Red Hat Enterprise Linux 7 and later
- confined user mapped to sysadm_u or transitioning to sysadm_r
- newaliases
- SELinux
-
/etc/sudoers%wheel ALL=(ALL) TYPE=sysadm_t ROLE=sysadm_r ALL
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.