Bug 1471361 - SELinux is preventing systemd-sleep from 'create' accesses on the file state.
Summary: SELinux is preventing systemd-sleep from 'create' accesses on the file state.
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 26
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Lukas Vrabec
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:dec254d503744aca63457d80ddf...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-07-15 09:20 UTC by Geoff Ericksson
Modified: 2017-11-15 20:10 UTC (History)
18 users (show)

Fixed In Version: selinux-policy-3.13.1-260.14.fc26
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-11-15 20:10:06 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Geoff Ericksson 2017-07-15 09:20:34 UTC
Description of problem:
SELinux is preventing systemd-sleep from 'create' accesses on the file state.

*****  Plugin catchall (100. confidence) suggests   **************************

If you believe that systemd-sleep should be allowed create access on the state 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-sleep' --raw | audit2allow -M my-systemdsleep
# semodule -X 300 -i my-systemdsleep.pp

Additional Information:
Source Context                system_u:system_r:init_t:s0
Target Context                system_u:object_r:sysfs_t:s0
Target Objects                state [ file ]
Source                        systemd-sleep
Source Path                   systemd-sleep
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-225.18.fc25.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 4.11.6-201.fc25.x86_64 #1 SMP Tue
                              Jun 20 20:21:11 UTC 2017 x86_64 x86_64
Alert Count                   3
First Seen                    2017-06-03 20:30:16 AEST
Last Seen                     2017-07-11 18:02:31 AEST
Local ID                      99d2d45f-6978-4145-8e6f-caa276a466ee

Raw Audit Messages
type=AVC msg=audit(1499760151.570:1193): avc:  denied  { create } for  pid=29903 comm="systemd-sleep" name="state" scontext=system_u:system_r:init_t:s0 tcontext=system_u:object_r:sysfs_t:s0 tclass=file permissive=0


Hash: systemd-sleep,init_t,sysfs_t,file,create

Version-Release number of selected component:
selinux-policy-3.13.1-225.18.fc25.noarch

Additional info:
component:      selinux-policy
reporter:       libreport-2.9.1
hashmarkername: setroubleshoot
kernel:         4.11.9-300.fc26.x86_64
type:           libreport

Potential duplicate: bug 1380300

Comment 1 Igor 2017-09-06 16:14:06 UTC
Description of problem:
Dell xps 13 9350. put the charge. notebook was in suspend. Wake up from suspend and show notification with error

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

Additional info:
reporter:       libreport-2.9.1
hashmarkername: setroubleshoot
kernel:         4.12.9-300.fc26.x86_64
type:           libreport

Comment 2 Timur Kristóf 2017-09-26 18:26:26 UTC
Description of problem:
Happened after sleep-resume, not sure why.

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

Additional info:
reporter:       libreport-2.9.1
hashmarkername: setroubleshoot
kernel:         4.13.2-300.fc27.x86_64
type:           libreport

Comment 3 peterbabos 2017-09-27 20:58:23 UTC
Description of problem:
my laptop was on even it had to be in sleep mode

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

Additional info:
reporter:       libreport-2.9.1
hashmarkername: setroubleshoot
kernel:         4.12.13-300.fc26.x86_64
type:           libreport

Comment 4 Timur Kristóf 2017-10-01 09:44:45 UTC
Description of problem:
I saw this after a suspend-resume cycle.

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

Additional info:
reporter:       libreport-2.9.1
hashmarkername: setroubleshoot
kernel:         4.13.2-300.fc27.x86_64
type:           libreport

Comment 5 Giovanni Cassetta 2017-10-12 21:07:36 UTC
Description of problem:
The problem occurred when I closed the screen of my laptop

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

Additional info:
reporter:       libreport-2.9.1
hashmarkername: setroubleshoot
kernel:         4.12.14-300.fc26.x86_64
type:           libreport

Comment 6 Fedora Update System 2017-10-26 12:30:52 UTC
selinux-policy-3.13.1-260.14.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-d312739a4e

Comment 7 Dan Dragomir 2017-10-31 14:42:33 UTC
This also happens on Fedora 25, but the relevant bug (Bug 1383872) seems to be closed as WORKSFORME for some time now.


SELinux is preventing systemd-sleep from create access on the file state.

*****  Plugin catchall (100. confidence) suggests   **************************

If you believe that systemd-sleep should be allowed create access on the state 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-sleep' --raw | audit2allow -M my-systemdsleep
# semodule -X 300 -i my-systemdsleep.pp

Additional Information:
Source Context                system_u:system_r:init_t:s0
Target Context                system_u:object_r:sysfs_t:s0
Target Objects                state [ file ]
Source                        systemd-sleep
Source Path                   systemd-sleep
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-225.19.fc25.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux tauron 4.11.12-200.fc25.x86_64 #1 SMP Fri
                              Jul 21 16:41:43 UTC 2017 x86_64 x86_64
Alert Count                   3
First Seen                    2017-08-11 19:05:45 EEST
Last Seen                     2017-08-17 10:39:58 EEST
Local ID                      93b8ace1-6acb-4ec5-b0a6-54df90b15ad3

Raw Audit Messages
type=AVC msg=audit(1502955598.551:2626): avc:  denied  { create } for  pid=9537 comm="systemd-sleep" name="state" scontext=system_u:system_r:init_t:s0 tcontext=system_u:object_r:sysfs_t:s0 tclass=file permissive=0


Hash: systemd-sleep,init_t,sysfs_t,file,create

Comment 8 Lukas Vrabec 2017-11-01 16:41:51 UTC
Backported also to F25

Comment 9 Fedora Update System 2017-11-15 20:10:06 UTC
selinux-policy-3.13.1-260.14.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.


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