Bug 1727934

Summary: selinux denial when running NetworkManager with dhcp=dhclient
Product: Red Hat Enterprise Linux 8 Reporter: Jan Tluka <jtluka>
Component: NetworkManagerAssignee: Beniamino Galvani <bgalvani>
Status: CLOSED DUPLICATE QA Contact: Desktop QE <desktop-qa-list>
Severity: high Docs Contact:
Priority: high    
Version: 8.1CC: atragler, bgalvani, fgiudici, lnst-team, lrintel, rkhan, sukulkar, thaller
Target Milestone: rcKeywords: Regression
Target Release: 8.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: LNST
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-08-12 14:15:17 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jan Tluka 2019-07-08 15:13:54 UTC
Description of problem:

After update of RHEL-8.1.0 compose from RHEL-8.1.0-20190604.7 to  RHEL-8.1.0-20190619.2 I hit following selinux denial:

time->Sun Jul  7 11:06:22 2019
type=PROCTITLE msg=audit(1562511982.369:33): proctitle=2F7362696E2F6468636C69656E74002D64002D71002D7366002F7573722F6C6962657865632F6E6D2D646863702D68656C706572002D7066002F72756E2F4E6574776F726B4D616E616765722F6468636C69656E742D657468302E706964002D6C66002F7661722F6C69622F4E6574776F726B4D616E616765722F6468636C69
type=SYSCALL msg=audit(1562511982.369:33): arch=c000003e syscall=257 success=no exit=-13 a0=ffffff9c a1=7ffea51c0e9a a2=80241 a3=1a4 items=0 ppid=811 pid=884 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="dhclient" exe="/usr/sbin/dhclient" subj=system_u:system_r:dhcpc_t:s0 key=(null)
type=AVC msg=audit(1562511982.369:33): avc:  denied  { write } for  pid=884 comm="dhclient" name="NetworkManager" dev="tmpfs" ino=22589 scontext=system_u:system_r:dhcpc_t:s0 tcontext=system_u:object_r:NetworkManager_var_run_t:s0 tclass=dir permissive=0

I have this modification of NetworkManager configuration:
echo -e "[main]\ndhcp=dhclient" > /etc/NetworkManager/conf.d/lnst.conf

There were two changes between the two composes that may have caused this issue:
selinux-policy-3.14.3-7.el8 -> selinux-policy-3.14.3-9.el8
NetworkManager-1:1.14.0-14.el8 -> NetworkManager-1:1.20.0-0.1.el8

Version-Release number of selected component (if applicable):
NetworkManager-1:1.20.0-0.1.el8
selinux-policy-3.14.3-9.el8

How reproducible:
100%

Steps to Reproduce:
1. clone this beaker job https://beaker.engineering.redhat.com/jobs/3654957
or simply setup NetworkManager to use dhclient for DHCP instead of internal one that seems to work without any issues
2.
3.

Actual results:
selinux denial

Expected results:
no selinux denial

Additional info:

Comment 2 Beniamino Galvani 2019-08-12 14:15:17 UTC

*** This bug has been marked as a duplicate of bug 1720070 ***