Bug 1278659 - SELinux is preventing systemd-logind from read, write, open access on the file /run/systemd/shutdown/.#scheduledPlE1Q9.
SELinux is preventing systemd-logind from read, write, open access on the fil...
Status: CLOSED DUPLICATE of bug 1277987
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
23
x86_64 Unspecified
medium Severity high
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
abrt_hash:9a8f1f8b22a60d3f78477982c22...
:
: 1278657 1278658 1278660 1278666 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-11-06 00:52 EST by Vinicius Reis
Modified: 2015-11-10 07:10 EST (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-11-10 07:10:08 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Vinicius Reis 2015-11-06 00:52:50 EST
Description of problem:
SELinux is preventing systemd-logind from read, write, open access on the file /run/systemd/shutdown/.#scheduledPlE1Q9.

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

If você acredita que o systemd-logind deva ser permitido acesso de read write open em .#scheduledPlE1Q9 file  por default.
Then você precisa reportar este como um erro.
Você pode gerar um módulo de política local para permitir este acesso.
Do
permitir este acesso agora executando:
# grep systemd-logind /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:systemd_logind_t:s0
Target Context                system_u:object_r:init_var_run_t:s0
Target Objects                /run/systemd/shutdown/.#scheduledPlE1Q9 [ file ]
Source                        systemd-logind
Source Path                   systemd-logind
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-152.fc23.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Permissive
Host Name                     (removed)
Platform                      Linux (removed) 4.2.5-300.fc23.x86_64 #1 SMP Tue
                              Oct 27 04:29:56 UTC 2015 x86_64 x86_64
Alert Count                   1
First Seen                    2015-11-06 03:37:46 BRST
Last Seen                     2015-11-06 03:37:46 BRST
Local ID                      98372616-f82e-4d3b-b4e9-718347149c20

Raw Audit Messages
type=AVC msg=audit(1446788266.910:622): avc:  denied  { read write open } for  pid=757 comm="systemd-logind" path="/run/systemd/shutdown/.#scheduledPlE1Q9" dev="tmpfs" ino=279971 scontext=system_u:system_r:systemd_logind_t:s0 tcontext=system_u:object_r:init_var_run_t:s0 tclass=file permissive=1


Hash: systemd-logind,systemd_logind_t,init_var_run_t,file,read,write,open

Version-Release number of selected component:
selinux-policy-3.13.1-152.fc23.noarch

Additional info:
reporter:       libreport-2.6.3
hashmarkername: setroubleshoot
kernel:         4.2.5-300.fc23.x86_64
type:           libreport
Comment 1 Miroslav Grepl 2015-11-09 02:33:08 EST
*** Bug 1278658 has been marked as a duplicate of this bug. ***
Comment 2 Miroslav Grepl 2015-11-09 02:33:18 EST
*** Bug 1278660 has been marked as a duplicate of this bug. ***
Comment 3 Miroslav Grepl 2015-11-09 02:33:44 EST
*** Bug 1278666 has been marked as a duplicate of this bug. ***
Comment 4 Miroslav Grepl 2015-11-09 02:35:02 EST
*** Bug 1278657 has been marked as a duplicate of this bug. ***
Comment 5 Miroslav Grepl 2015-11-09 03:16:01 EST
Could you please add your reproducer for this issue? Thank you.
Comment 6 Vinicius Reis 2015-11-09 08:09:23 EST
Hello, thank you for helping.
These are the steps:

1- Put SELinux in permissive mode and reboot;
2- Login as a ordinary user and run a scheduled shutdown (sudo shutdown -h 10:00, for example);

When SELinux is in enforcing mode, I've not found any warning, but shutdown fails and ignore the TIME parameter, shutting down the system immediately. So to get these warnings SELinux need to be in permissive mode.
Comment 7 Vinicius Reis 2015-11-09 13:12:05 EST
It may be useful to see https://bugzilla.redhat.com/show_bug.cgi?id=1277987.
It's another warning from SELinux I've received while trying to shutdown the machine with a TIME argument, so it could provide more information, or just can be marked as DUPLICATE of this issue.
Comment 8 Miroslav Grepl 2015-11-10 07:10:08 EST

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

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