Description of problem: The rngd service is currently running as root with full capabilities. If this daemon can be run in a less privileged way, this would help the security posture of the OS. Steps to Reproduce: 1. pscap | grep rngd 2. observer "full" is given for capabilities. Additional info: Initial review suggests that CAP_SYS_ADMIN is all that is needed.
currently this effort is blocked because rngd needs access to the random_wakeup_threshold sysctl value which is owned by root and is only writeable by the root user.
changes ready to be merged here: https://src.osci.redhat.com/rpms/rng-tools/pull-request/2
ack.
Hi Neil, where should this be fixed? I cannot see it working in latest 8.1: # pscap | grep rngd 1 1767 root rngd full rng-tools-6.6-2.el8.x86_64 RHEL-8.1.0-20190718.n.2 BaseOS x86_64 Was the patch merged at all? # grep CAP_SYS_ADMIN /usr/lib/systemd/system/rngd.service | wc -l 0
yes, it was fixed in rng-tools-6.6-3. why is rng-tools-6.6-2 still in the compose?
Neil, latest 8.1.0 (RHEL-8.1.0-20190815.n.0 BaseOS x86_64) still only has rng-tools-6.6-2.el8.x86_64 . No newer version exists even in brewroot - see http://download.eng.brq.redhat.com/brewroot/packages/rng-tools/6.6/ . Are you sure you have built the patched version?
Looks fixed: [root@lenovo-sr650-01 ~]# pscap | grep rngd 1 1920 root rngd full [root@lenovo-sr650-01 ~]# cat /etc/redhat-release Red Hat Enterprise Linux release 8.1 (Ootpa) [root@intel-canoepass-03 ~]# pscap | grep rngd 1 1293 rngd rngd sys_admin [root@intel-canoepass-03 ~]# cat /etc/redhat-release Red Hat Enterprise Linux release 8.2 Beta (Ootpa)
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://access.redhat.com/errata/RHBA-2020:1762