Bug 1623589 - SELinux policy blocking iscsiuio from managing UIO interface to bnx2i/qedi drivers
Summary: SELinux policy blocking iscsiuio from managing UIO interface to bnx2i/qedi dr...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: selinux-policy
Version: 7.6
Hardware: Unspecified
OS: Linux
unspecified
urgent
Target Milestone: rc
: ---
Assignee: Lukas Vrabec
QA Contact: Milos Malik
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-08-29 17:14 UTC by Chris Leech
Modified: 2018-10-30 10:10 UTC (History)
10 users (show)

Fixed In Version: selinux-policy-3.13.1-223.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-10-30 10:09:38 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:3111 None None None 2018-10-30 10:10:13 UTC

Description Chris Leech 2018-08-29 17:14:13 UTC
Description of problem:

The iscsiuio process cannot configure the network settings of bnx2i or qedi iSCSI HBAs from userspace, as access to the UIO devices is now being blocked.

I'm not sure what or when the impacting policy change was.

Version-Release number of selected component (if applicable):

selinux-policy-3.13.1-221.el7.noarch

How reproducible:

100%

Steps to Reproduce:
1. configure iface.ipaddress on offload iface
2. attempt iSCSI SendTargets discovery over the offload iface

Actual results:

iscsiadm: Connection to discovery portal 172.17.20.18 failed: operation failed but retry may succeed
iscsiadm: Could not set host net params (err 29)

Expected results:

configure HBA and connect to iSCSI target

Additional info:

type=AVC msg=audit(1535562523.017:109): avc:  denied  { map } for  pid=15918 comm="iscsiuio" path="/dev/uio0" dev="de0
	Was caused by:
		Missing type enforcement (TE) allow rule.

		You can use audit2allow to generate a loadable module to allow this access.

#============= iscsid_t ==============
allow iscsid_t userio_device_t:chr_file map;

Comment 3 Milos Malik 2018-08-29 18:59:30 UTC
The SELinux denial mentioned in comment#0 is not complete. Please collect SELinux denials and attach them here:

# ausearch -m avc -m user_avc -m selinux_err -m user_selinux_err -i -ts today

Thank you.

Comment 4 Chris Leech 2018-08-29 22:16:44 UTC
(In reply to Milos Malik from comment #3)
> The SELinux denial mentioned in comment#0 is not complete. Please collect
> SELinux denials and attach them here:
> 
> # ausearch -m avc -m user_avc -m selinux_err -m user_selinux_err -i -ts today
> 
> Thank you.

# ausearch -m avc -m user_avc -m selinux_err -m user_selinux_err -i -ts boot
----
type=PROCTITLE msg=audit(08/29/2018 18:14:23.782:71) : proctitle=/usr/sbin/iscsiuio 
type=SYSCALL msg=audit(08/29/2018 18:14:23.782:71) : arch=x86_64 syscall=mmap success=no exit=EACCES(Permission denied) a0=0x0 a1=0x38 a2=PROT_READ|PROT_WRITE a3=MAP_SHARED items=0 ppid=1 pid=16289 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=iscsiuio exe=/usr/sbin/iscsiuio subj=system_u:system_r:iscsid_t:s0 key=(null) 
type=AVC msg=audit(08/29/2018 18:14:23.782:71) : avc:  denied  { map } for  pid=16289 comm=iscsiuio path=/dev/uio0 dev="devtmpfs" ino=79930 scontext=system_u:system_r:iscsid_t:s0 tcontext=system_u:object_r:userio_device_t:s0 tclass=chr_file permissive=0 
----
type=PROCTITLE msg=audit(08/29/2018 18:14:24.805:72) : proctitle=/usr/sbin/iscsiuio 
type=SYSCALL msg=audit(08/29/2018 18:14:24.805:72) : arch=x86_64 syscall=mmap success=no exit=EACCES(Permission denied) a0=0x0 a1=0x38 a2=PROT_READ|PROT_WRITE a3=MAP_SHARED items=0 ppid=1 pid=16289 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=iscsiuio exe=/usr/sbin/iscsiuio subj=system_u:system_r:iscsid_t:s0 key=(null) 
type=AVC msg=audit(08/29/2018 18:14:24.805:72) : avc:  denied  { map } for  pid=16289 comm=iscsiuio path=/dev/uio0 dev="devtmpfs" ino=79930 scontext=system_u:system_r:iscsid_t:s0 tcontext=system_u:object_r:userio_device_t:s0 tclass=chr_file permissive=0 
----
type=PROCTITLE msg=audit(08/29/2018 18:14:25.828:73) : proctitle=/usr/sbin/iscsiuio 
type=SYSCALL msg=audit(08/29/2018 18:14:25.828:73) : arch=x86_64 syscall=mmap success=no exit=EACCES(Permission denied) a0=0x0 a1=0x38 a2=PROT_READ|PROT_WRITE a3=MAP_SHARED items=0 ppid=1 pid=16289 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=iscsiuio exe=/usr/sbin/iscsiuio subj=system_u:system_r:iscsid_t:s0 key=(null) 
type=AVC msg=audit(08/29/2018 18:14:25.828:73) : avc:  denied  { map } for  pid=16289 comm=iscsiuio path=/dev/uio0 dev="devtmpfs" ino=79930 scontext=system_u:system_r:iscsid_t:s0 tcontext=system_u:object_r:userio_device_t:s0 tclass=chr_file permissive=0 
----
type=PROCTITLE msg=audit(08/29/2018 18:14:28.774:75) : proctitle=/usr/sbin/iscsiuio 
type=SYSCALL msg=audit(08/29/2018 18:14:28.774:75) : arch=x86_64 syscall=mmap success=no exit=EACCES(Permission denied) a0=0x0 a1=0x38 a2=PROT_READ|PROT_WRITE a3=MAP_SHARED items=0 ppid=1 pid=16289 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=iscsiuio exe=/usr/sbin/iscsiuio subj=system_u:system_r:iscsid_t:s0 key=(null) 
type=AVC msg=audit(08/29/2018 18:14:28.774:75) : avc:  denied  { map } for  pid=16289 comm=iscsiuio path=/dev/uio0 dev="devtmpfs" ino=79930 scontext=system_u:system_r:iscsid_t:s0 tcontext=system_u:object_r:userio_device_t:s0 tclass=chr_file permissive=0 
----
type=PROCTITLE msg=audit(08/29/2018 18:14:27.751:74) : proctitle=/usr/sbin/iscsiuio 
type=SYSCALL msg=audit(08/29/2018 18:14:27.751:74) : arch=x86_64 syscall=mmap success=no exit=EACCES(Permission denied) a0=0x0 a1=0x38 a2=PROT_READ|PROT_WRITE a3=MAP_SHARED items=0 ppid=1 pid=16289 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=iscsiuio exe=/usr/sbin/iscsiuio subj=system_u:system_r:iscsid_t:s0 key=(null) 
type=AVC msg=audit(08/29/2018 18:14:27.751:74) : avc:  denied  { map } for  pid=16289 comm=iscsiuio path=/dev/uio0 dev="devtmpfs" ino=79930 scontext=system_u:system_r:iscsid_t:s0 tcontext=system_u:object_r:userio_device_t:s0 tclass=chr_file permissive=0 
----
type=PROCTITLE msg=audit(08/29/2018 18:14:29.797:76) : proctitle=/usr/sbin/iscsiuio 
type=SYSCALL msg=audit(08/29/2018 18:14:29.797:76) : arch=x86_64 syscall=mmap success=no exit=EACCES(Permission denied) a0=0x0 a1=0x38 a2=PROT_READ|PROT_WRITE a3=MAP_SHARED items=0 ppid=1 pid=16289 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=iscsiuio exe=/usr/sbin/iscsiuio subj=system_u:system_r:iscsid_t:s0 key=(null) 
type=AVC msg=audit(08/29/2018 18:14:29.797:76) : avc:  denied  { map } for  pid=16289 comm=iscsiuio path=/dev/uio0 dev="devtmpfs" ino=79930 scontext=system_u:system_r:iscsid_t:s0 tcontext=system_u:object_r:userio_device_t:s0 tclass=chr_file permissive=0 
----
type=PROCTITLE msg=audit(08/29/2018 18:14:32.781:78) : proctitle=/usr/sbin/iscsiuio 
type=SYSCALL msg=audit(08/29/2018 18:14:32.781:78) : arch=x86_64 syscall=mmap success=no exit=EACCES(Permission denied) a0=0x0 a1=0x38 a2=PROT_READ|PROT_WRITE a3=MAP_SHARED items=0 ppid=1 pid=16289 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=iscsiuio exe=/usr/sbin/iscsiuio subj=system_u:system_r:iscsid_t:s0 key=(null) 
type=AVC msg=audit(08/29/2018 18:14:32.781:78) : avc:  denied  { map } for  pid=16289 comm=iscsiuio path=/dev/uio0 dev="devtmpfs" ino=79930 scontext=system_u:system_r:iscsid_t:s0 tcontext=system_u:object_r:userio_device_t:s0 tclass=chr_file permissive=0 
----
type=PROCTITLE msg=audit(08/29/2018 18:14:33.804:79) : proctitle=/usr/sbin/iscsiuio 
type=SYSCALL msg=audit(08/29/2018 18:14:33.804:79) : arch=x86_64 syscall=mmap success=no exit=EACCES(Permission denied) a0=0x0 a1=0x38 a2=PROT_READ|PROT_WRITE a3=MAP_SHARED items=0 ppid=1 pid=16289 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=iscsiuio exe=/usr/sbin/iscsiuio subj=system_u:system_r:iscsid_t:s0 key=(null) 
type=AVC msg=audit(08/29/2018 18:14:33.804:79) : avc:  denied  { map } for  pid=16289 comm=iscsiuio path=/dev/uio0 dev="devtmpfs" ino=79930 scontext=system_u:system_r:iscsid_t:s0 tcontext=system_u:object_r:userio_device_t:s0 tclass=chr_file permissive=0 
----
type=PROCTITLE msg=audit(08/29/2018 18:14:31.758:77) : proctitle=/usr/sbin/iscsiuio 
type=SYSCALL msg=audit(08/29/2018 18:14:31.758:77) : arch=x86_64 syscall=mmap success=no exit=EACCES(Permission denied) a0=0x0 a1=0x38 a2=PROT_READ|PROT_WRITE a3=MAP_SHARED items=0 ppid=1 pid=16289 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=iscsiuio exe=/usr/sbin/iscsiuio subj=system_u:system_r:iscsid_t:s0 key=(null) 
type=AVC msg=audit(08/29/2018 18:14:31.758:77) : avc:  denied  { map } for  pid=16289 comm=iscsiuio path=/dev/uio0 dev="devtmpfs" ino=79930 scontext=system_u:system_r:iscsid_t:s0 tcontext=system_u:object_r:userio_device_t:s0 tclass=chr_file permissive=0

Comment 9 errata-xmlrpc 2018-10-30 10:09:38 UTC
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-2018:3111


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