Bug 1264493

Summary: SELinux is preventing rhsmd from 'write' accesses on the directory /sys/fs/fuse/connections.
Product: [Fedora] Fedora Reporter: David Poulsen <angakkeq>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 21CC: dominick.grift, dwalsh, lvrabec, mgrepl, plautrba
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:e9d4c25e3d5f42e3d5b4be77be17f43da78fb62b1cceddcfafc2a36b23da52c6
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1270778 (view as bug list) Environment:
Last Closed: 2015-10-12 11:21:07 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1270778    

Description David Poulsen 2015-09-18 15:13:37 UTC
Description of problem:
New user login as admin and new connection on mobile device hotspot
SELinux is preventing rhsmd from 'write' accesses on the directory /sys/fs/fuse/connections.

*****  Plugin restorecon (99.5 confidence) suggests   ************************

If you want to fix the label. 
/sys/fs/fuse/connections default label should be sysfs_t.
Then you can run restorecon.
Do
# /sbin/restorecon -v /sys/fs/fuse/connections

*****  Plugin catchall (1.49 confidence) suggests   **************************

If you believe that rhsmd should be allowed write access on the connections directory by default.
Then you should report this as a bug.
You can generate a local policy module to allow this access.
Do
allow this access for now by executing:
# grep rhsmd /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:rhsmcertd_t:s0-s0:c0.c1023
Target Context                system_u:object_r:fusefs_t:s0
Target Objects                /sys/fs/fuse/connections [ dir ]
Source                        rhsmd
Source Path                   rhsmd
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-105.20.fc21.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 4.0.4-201.fc21.x86_64 #1 SMP Thu
                              May 21 15:58:47 UTC 2015 x86_64 x86_64
Alert Count                   4
First Seen                    2015-09-18 17:10:08 CEST
Last Seen                     2015-09-18 17:10:08 CEST
Local ID                      f18d7145-2c07-4e80-83da-32db79d6998f

Raw Audit Messages
type=AVC msg=audit(1442589008.143:1222): avc:  denied  { write } for  pid=20949 comm="rhsmd" name="/" dev="fusectl" ino=1 scontext=system_u:system_r:rhsmcertd_t:s0-s0:c0.c1023 tcontext=system_u:object_r:fusefs_t:s0 tclass=dir permissive=0


Hash: rhsmd,rhsmcertd_t,fusefs_t,dir,write

Version-Release number of selected component:
selinux-policy-3.13.1-105.20.fc21.noarch

Additional info:
reporter:       libreport-2.3.0
hashmarkername: setroubleshoot
kernel:         4.0.4-201.fc21.x86_64
type:           libreport

Comment 1 David Poulsen 2015-09-21 19:33:45 UTC
Description of problem:
Reboot after software updates and installatino

Version-Release number of selected component:
selinux-policy-3.13.1-105.20.fc21.noarch

Additional info:
reporter:       libreport-2.3.0
hashmarkername: setroubleshoot
kernel:         4.0.4-201.fc21.x86_64
type:           libreport

Comment 2 Miroslav Grepl 2015-10-12 11:21:07 UTC
You can allow it using

# grep rhsmcertd_t /var/log/audit/audit.log |audit2allow -M mypol
# semodule -i mypol.pp


to make it working on F21. If we see it on F22+ we will fix it in the policy. Thank you.