Bug 1364816

Summary: SELinux is preventing systemd from 'getattr' accesses on the blk_file /run/systemd/inaccessible/blk.
Product: [Fedora] Fedora Reporter: Zdenek Chmelar <chmelarz>
Component: selinux-policyAssignee: Lukas Vrabec <lvrabec>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: dominick.grift, dwalsh, em3rson, lvrabec, mgrepl, nicolas.mailhot, plautrba
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:bd359d4c7dd5dbb65b3aa1d52ebf31cf8b2897b444bb5503b048ad55d3671d64;VARIANT_ID=workstation;
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-08-16 15:20:08 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:

Description Zdenek Chmelar 2016-08-07 20:06:41 UTC
Description of problem:
Error popped up after login to desktop
SELinux is preventing systemd from 'getattr' accesses on the blk_file /run/systemd/inaccessible/blk.

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

If you want to fix the label. 
/run/systemd/inaccessible/blk default label should be init_var_run_t.
Then you can run restorecon.
Do
# /sbin/restorecon -v /run/systemd/inaccessible/blk

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

If you believe that systemd should be allowed getattr access on the blk blk_file 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:
# ausearch -c 'systemd' --raw | audit2allow -M my-systemd
# semodule -X 300 -i my-systemd.pp

Additional Information:
Source Context                system_u:system_r:init_t:s0
Target Context                system_u:object_r:tmpfs_t:s0
Target Objects                /run/systemd/inaccessible/blk [ blk_file ]
Source                        systemd
Source Path                   systemd
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-206.fc26.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 4.8.0-0.rc0.git5.1.fc26.x86_64 #1
                              SMP Wed Aug 3 09:59:24 UTC 2016 x86_64 x86_64
Alert Count                   10
First Seen                    2016-08-07 21:53:49 CEST
Last Seen                     2016-08-07 22:03:30 CEST
Local ID                      2dea9f89-1b2f-405f-ace2-4d7701c939bd

Raw Audit Messages
type=AVC msg=audit(1470600210.617:273): avc:  denied  { getattr } for  pid=1 comm="systemd" path="/run/systemd/inaccessible/blk" dev="tmpfs" ino=1191 scontext=system_u:system_r:init_t:s0 tcontext=system_u:object_r:tmpfs_t:s0 tclass=blk_file permissive=0


Hash: systemd,init_t,tmpfs_t,blk_file,getattr

Version-Release number of selected component:
selinux-policy-3.13.1-206.fc26.noarch

Additional info:
reporter:       libreport-2.7.2
hashmarkername: setroubleshoot
kernel:         4.8.0-0.rc0.git5.1.fc26.x86_64
type:           libreport

Comment 1 Lukas Vrabec 2016-08-16 15:20:08 UTC

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