Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
When using certain SELinux policies, such as the MLS policy, it was not possible to properly mount the cgroupfs file system due to the way security checks were applied to the new cgroupfs inodes during the mount operation. With this update, the security checks applied during the mount operation have been changed so that they always succeed, and the cgroupfs file system can now be successfully mounted and used with the MLS SELinux policy. This issue did not affect systems which used the default targeted policy.
Description of problem:
Found following AVC denials for cgroups after (re)boot of my CCC system in MLS mode on latest 6.1 tree. Not sure about how this affects functionality of cgroups.
# cat cgroup.log | ausearch -i
----
type=AVC msg=audit(04/28/2011 08:41:26.404:6) : avc: denied { search } for pid=918 comm=cgconfigparser name=/ dev=cgroup ino=10217 scontext=system_u:system_r:cgconfig_t:s0-s15:c0.c1023 tcontext=system_u:object_r:unlabeled_t:s15:c0.c1023 tclass=dir
type=SYSCALL msg=audit(04/28/2011 08:41:26.404:6) : arch=x86_64 syscall=mount success=yes exit=0 a0=7f1a3188b481 a1=7f1a31a8f400 a2=7f1a3188b481 a3=0 items=0 ppid=917 pid=918 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=cgconfigparser exe=/sbin/cgconfigparser subj=system_u:system_r:cgconfig_t:s0-s15:c0.c1023 key=(null)
----
type=AVC msg=audit(04/28/2011 08:41:26.404:7) : avc: denied { search } for pid=918 comm=cgconfigparser name=/ dev=cgroup ino=10218 scontext=system_u:system_r:cgconfig_t:s0-s15:c0.c1023 tcontext=system_u:object_r:unlabeled_t:s15:c0.c1023 tclass=dir
type=SYSCALL msg=audit(04/28/2011 08:41:26.404:7) : arch=x86_64 syscall=mount success=yes exit=0 a0=7f1a3188b481 a1=7f1a31a91404 a2=7f1a3188b481 a3=0 items=0 ppid=917 pid=918 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=cgconfigparser exe=/sbin/cgconfigparser subj=system_u:system_r:cgconfig_t:s0-s15:c0.c1023 key=(null)
----
...
Searching for the inode numbers shows that the cgconfigparser wants to search for dirs under /cgroup/ which are for some to me unknown reason unlabeled_t at the time it does the search, though it they have the labels set correctly:
# ll -Z /cgroup/
drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow blkio
drwxr-xr-x. eal root system_u:object_r:cgroup_t:SystemLow cpu
drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow cpuacct
drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow cpuset
drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow devices
drwxr-xr-x. eal root system_u:object_r:cgroup_t:SystemLow freezer
drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow memory
drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow net_cls
Version-Release number of selected component (if applicable):
# rpm -q selinux-policy libcgroup
selinux-policy-3.7.19-87.el6.noarch
libcgroup-0.37-2.el6.x86_64
How reproducible:
always
Steps to Reproduce:
1. configure CCC system in MLS mode
2. (re)boot
3. check for AVCs in audit.log
Actual results:
avc denials
Expected results:
no avc denials :)
Additional info:
#============= cgconfig_t ==============
#!!!! This avc is a constraint violation. You will need to add an attribute to either the source or target type to make it work.
#Contraint rule:
allow cgconfig_t unlabeled_t:dir search;
(In reply to comment #2)
> Do you see anything about selinux in dmesg or do you see anything from ausearch
> -m SELINUX_ERR ??
No, there is nothing suspicious in dmesg or audit.log.
Technical note added. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.
New Contents:
When using certain SELinux policies, such as the MLS policy, it was not possible to properly mount the cgroupfs file system due to the way security checks were applied to the new cgroupfs inodes during the mount operation. With this update, the security checks applied during the mount operation have been changed so that they always succeed, and the cgroupfs file system can now be successfully mounted and used with the MLS SELinux policy. This issue did not affect systems which used the default targeted policy.
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.
http://rhn.redhat.com/errata/RHSA-2011-1530.html
Description of problem: Found following AVC denials for cgroups after (re)boot of my CCC system in MLS mode on latest 6.1 tree. Not sure about how this affects functionality of cgroups. # cat cgroup.log | ausearch -i ---- type=AVC msg=audit(04/28/2011 08:41:26.404:6) : avc: denied { search } for pid=918 comm=cgconfigparser name=/ dev=cgroup ino=10217 scontext=system_u:system_r:cgconfig_t:s0-s15:c0.c1023 tcontext=system_u:object_r:unlabeled_t:s15:c0.c1023 tclass=dir type=SYSCALL msg=audit(04/28/2011 08:41:26.404:6) : arch=x86_64 syscall=mount success=yes exit=0 a0=7f1a3188b481 a1=7f1a31a8f400 a2=7f1a3188b481 a3=0 items=0 ppid=917 pid=918 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=cgconfigparser exe=/sbin/cgconfigparser subj=system_u:system_r:cgconfig_t:s0-s15:c0.c1023 key=(null) ---- type=AVC msg=audit(04/28/2011 08:41:26.404:7) : avc: denied { search } for pid=918 comm=cgconfigparser name=/ dev=cgroup ino=10218 scontext=system_u:system_r:cgconfig_t:s0-s15:c0.c1023 tcontext=system_u:object_r:unlabeled_t:s15:c0.c1023 tclass=dir type=SYSCALL msg=audit(04/28/2011 08:41:26.404:7) : arch=x86_64 syscall=mount success=yes exit=0 a0=7f1a3188b481 a1=7f1a31a91404 a2=7f1a3188b481 a3=0 items=0 ppid=917 pid=918 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=cgconfigparser exe=/sbin/cgconfigparser subj=system_u:system_r:cgconfig_t:s0-s15:c0.c1023 key=(null) ---- ... Searching for the inode numbers shows that the cgconfigparser wants to search for dirs under /cgroup/ which are for some to me unknown reason unlabeled_t at the time it does the search, though it they have the labels set correctly: # ll -Z /cgroup/ drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow blkio drwxr-xr-x. eal root system_u:object_r:cgroup_t:SystemLow cpu drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow cpuacct drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow cpuset drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow devices drwxr-xr-x. eal root system_u:object_r:cgroup_t:SystemLow freezer drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow memory drwxr-xr-x. root root system_u:object_r:cgroup_t:SystemLow net_cls Version-Release number of selected component (if applicable): # rpm -q selinux-policy libcgroup selinux-policy-3.7.19-87.el6.noarch libcgroup-0.37-2.el6.x86_64 How reproducible: always Steps to Reproduce: 1. configure CCC system in MLS mode 2. (re)boot 3. check for AVCs in audit.log Actual results: avc denials Expected results: no avc denials :) Additional info: #============= cgconfig_t ============== #!!!! This avc is a constraint violation. You will need to add an attribute to either the source or target type to make it work. #Contraint rule: allow cgconfig_t unlabeled_t:dir search;