Bug 742696 - SELinux is preventing /bin/bash from 'open' accesses on the archivo /var/log/pm-suspend.log.
Summary: SELinux is preventing /bin/bash from 'open' accesses on the archivo /var/log/...
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 15
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: setroubleshoot_trace_hash:0d8d28b8a5c...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-10-01 17:09 UTC by Saúl
Modified: 2012-08-07 19:59 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-08-07 19:59:02 UTC
Type: ---


Attachments (Terms of Use)

Description Saúl 2011-10-01 17:09:38 UTC
SELinux is preventing /bin/bash from 'open' accesses on the archivo /var/log/pm-suspend.log.

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

If you believe that bash should be allowed open access on the pm-suspend.log 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:
# grep pm-hibernate /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:hald_t:s0
Target Context                system_u:object_r:devicekit_var_log_t:s0
Target Objects                /var/log/pm-suspend.log [ file ]
Source                        pm-hibernate
Source Path                   /bin/bash
Port                          <Desconocido>
Host                          (removed)
Source RPM Packages           bash-4.2.10-4.fc15
Target RPM Packages           pm-utils-1.4.1-8.fc15
Policy RPM                    selinux-policy-3.9.16-38.fc15
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 2.6.40.4-5.fc15.x86_64 #1 SMP Tue Aug
                              30 14:38:32 UTC 2011 x86_64 x86_64
Alert Count                   7
First Seen                    mié 14 sep 2011 16:19:39 CEST
Last Seen                     sáb 01 oct 2011 18:41:08 CEST
Local ID                      03e2c0fe-eeea-45fd-b3f6-c9c14de92202

Raw Audit Messages
type=AVC msg=audit(1317487268.524:73): avc:  denied  { open } for  pid=1865 comm="pm-hibernate" name="pm-suspend.log" dev=dm-1 ino=5721 scontext=system_u:system_r:hald_t:s0 tcontext=system_u:object_r:devicekit_var_log_t:s0 tclass=file


type=SYSCALL msg=audit(1317487268.524:73): arch=x86_64 syscall=open success=no exit=EACCES a0=16ff470 a1=401 a2=1b6 a3=fffffffffffffff0 items=0 ppid=1863 pid=1865 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=pm-hibernate exe=/bin/bash subj=system_u:system_r:hald_t:s0 key=(null)

Hash: pm-hibernate,hald_t,devicekit_var_log_t,file,open

audit2allow

#============= hald_t ==============
allow hald_t devicekit_var_log_t:file open;

audit2allow -R

#============= hald_t ==============
allow hald_t devicekit_var_log_t:file open;

Comment 1 Miroslav Grepl 2011-10-03 07:31:02 UTC
pm-suspend.log is mislabeled.

Execute

restorecon -R -v /var/log/pm-suspend.log

which will fix the issue and if this happens again, please reopen the bug.

Comment 2 Daniel Walsh 2011-10-03 14:47:30 UTC
matchpathcon /var/log/pm-suspend.log 
/var/log/pm-suspend.log	system_u:object_r:devicekit_var_log_t:s0


????

Comment 3 Miroslav Grepl 2011-10-04 06:04:38 UTC
Oops, I did matchpathcon on F14 instead of F15, F16.

Comment 4 Fedora End Of Life 2012-08-07 19:59:05 UTC
This message is a notice that Fedora 15 is now at end of life. Fedora
has stopped maintaining and issuing updates for Fedora 15. It is
Fedora's policy to close all bug reports from releases that are no
longer maintained. At this time, all open bugs with a Fedora 'version'
of '15' have been closed as WONTFIX.

(Please note: Our normal process is to give advanced warning of this
occurring, but we forgot to do that. A thousand apologies.)

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, feel free to reopen
this bug and simply change the 'version' to a later Fedora version.

Bug Reporter: Thank you for reporting this issue and we are sorry that
we were unable to fix it before Fedora 15 reached end of life. If you
would still like to see this bug fixed and are able to reproduce it
against a later version of Fedora, you are encouraged to click on
"Clone This Bug" (top right of this page) and open it against that
version of Fedora.

Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.

The process we are following is described here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping


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