Bug 800574 - SELinux is preventing /usr/sbin/skdump from 'ioctl' accesses on the blk_file /dev/sda.
SELinux is preventing /usr/sbin/skdump from 'ioctl' accesses on the blk_file ...
Status: CLOSED EOL
Product: Fedora
Classification: Fedora
Component: abrt (Show other bugs)
19
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: abrt
Fedora Extras Quality Assurance
abrt_hash:b044467e0738a8bed73b482deea...
: Reopened
: 800572 810741 977946 (view as bug list)
Depends On:
Blocks: 1004703
  Show dependency treegraph
 
Reported: 2012-03-06 13:30 EST by mamii
Modified: 2015-02-18 08:42 EST (History)
28 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-02-18 08:42:04 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
mtoman: needinfo+


Attachments (Terms of Use)

  None (edit)
Description mamii 2012-03-06 13:30:28 EST
libreport version: 2.0.8
executable:     /usr/bin/python
hashmarkername: setroubleshoot
kernel:         3.2.9-1.fc16.x86_64
reason:         SELinux is preventing /usr/sbin/skdump from 'ioctl' accesses on the blk_file /dev/sda.
time:           Tue 06 Mar 2012 07:30:12 PM CET

description:
:SELinux is preventing /usr/sbin/skdump from 'ioctl' accesses on the blk_file /dev/sda.
:
:*****  Plugin catchall (100. confidence) suggests  ***************************
:
:If you believe that skdump should be allowed ioctl access on the sda 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:
:# grep skdump /var/log/audit/audit.log | audit2allow -M mypol
:# semodule -i mypol.pp
:
:Additional Information:
:Source Context                system_u:system_r:abrt_t:s0-s0:c0.c1023
:Target Context                system_u:object_r:fixed_disk_device_t:s0
:Target Objects                /dev/sda [ blk_file ]
:Source                        skdump
:Source Path                   /usr/sbin/skdump
:Port                          <Unknown>
:Host                          (removed)
:Source RPM Packages           libatasmart-0.17-3.fc15.x86_64
:Target RPM Packages           
:Policy RPM                    selinux-policy-3.10.0-78.fc16.noarch
:Selinux Enabled               True
:Policy Type                   targeted
:Enforcing Mode                Permissive
:Host Name                     (removed)
:Platform                      Linux (removed) 3.2.9-1.fc16.x86_64 #1 SMP Thu Mar 1
:                              01:41:10 UTC 2012 x86_64 x86_64
:Alert Count                   1
:First Seen                    Tue 06 Mar 2012 06:27:31 PM CET
:Last Seen                     Tue 06 Mar 2012 06:27:31 PM CET
:Local ID                      05b8626f-ea28-4fa7-9a0a-8020410aca94
:
:Raw Audit Messages
:type=AVC msg=audit(1331054851.538:66): avc:  denied  { ioctl } for  pid=1946 comm="skdump" path="/dev/sda" dev=devtmpfs ino=7197 scontext=system_u:system_r:abrt_t:s0-s0:c0.c1023 tcontext=system_u:object_r:fixed_disk_device_t:s0 tclass=blk_file
:
:
:type=SYSCALL msg=audit(1331054851.538:66): arch=x86_64 syscall=ioctl success=yes exit=0 a0=3 a1=80081272 a2=18c7020 a3=9 items=0 ppid=1944 pid=1946 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=skdump exe=/usr/sbin/skdump subj=system_u:system_r:abrt_t:s0-s0:c0.c1023 key=(null)
:
:Hash: skdump,abrt_t,fixed_disk_device_t,blk_file,ioctl
:
:audit2allow
:
:#============= abrt_t ==============
:allow abrt_t fixed_disk_device_t:blk_file ioctl;
:
:audit2allow -R
:
:#============= abrt_t ==============
:allow abrt_t fixed_disk_device_t:blk_file ioctl;
:
Comment 1 Miroslav Grepl 2012-03-07 02:29:47 EST
*** Bug 800572 has been marked as a duplicate of this bug. ***
Comment 2 Miroslav Grepl 2012-03-07 02:30:16 EST
What is skdump and why is abrt executing it?
Comment 3 Michal Toman 2012-03-07 03:12:13 EST
It's a tool that collects SMART data from hard drives. This is a relevant information for a few packages.
Comment 4 Miroslav Grepl 2012-03-07 06:29:39 EST
Could you reproduce it with permissive mode to get all AVC msgs?
Comment 5 Daniel Walsh 2012-03-07 14:03:17 EST
This is a mighty dangerous access to give, basically this will end up allowing me to trigger abrt to read random content off of disks.
Comment 6 Miroslav Grepl 2012-03-08 04:20:30 EST
Yes, I was thinking about a transition. But still no ideal solution.
Comment 7 Daniel Walsh 2012-03-08 10:05:40 EST
So we have a tool that a non priv user can cause to run that reads a disk and then shows the output to the non priv user.  Seems like a bad idea.
Comment 8 Jiri Moskovcak 2012-03-08 10:35:43 EST
palimpsest reads the smart data even without root password, so I guess there is a safer way to get the smart data than using skdump..
Comment 9 Miroslav Grepl 2012-04-10 09:11:56 EDT
*** Bug 810741 has been marked as a duplicate of this bug. ***
Comment 10 Sander Scheepens 2012-08-10 08:04:54 EDT
I also get this problem:

SELinux is preventing /usr/sbin/skdump from read access on the blk_file sdb.

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

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

Additional Information:
Source Context                system_u:system_r:abrt_t:s0-s0:c0.c1023
Target Context                system_u:object_r:fixed_disk_device_t:s0
Target Objects                sdb [ blk_file ]
Source                        skdump
Source Path                   /usr/sbin/skdump
Port                          <Unknown>
Host                          -
Source RPM Packages           libatasmart-0.17-3.fc15.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.10.0-90.fc16.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     -
Platform                      Linux  3.4.6-1.fc16.x86_64 #1 SMP Fri Jul
                              20 12:58:04 UTC 2012 x86_64 x86_64
Alert Count                   2
First Seen                    Fri 10 Aug 2012 01:58:11 PM CEST
Last Seen                     Fri 10 Aug 2012 01:58:11 PM CEST
Local ID                      f9c0d436-767a-440b-85f6-52549a376809

Raw Audit Messages
type=AVC msg=audit(1344599891.258:1024): avc:  denied  { read } for  pid=17801 comm="skdump" name="sdb" dev="devtmpfs" ino=675071855 scontext=system_u:system_r:abrt_t:s0-s0:c0.c1023 tcontext=system_u:object_r:fixed_disk_device_t:s0 tclass=blk_file


type=SYSCALL msg=audit(1344599891.258:1024): arch=x86_64 syscall=open success=no exit=EACCES a0=11916a0 a1=80900 a2=0 a3=9 items=0 ppid=17798 pid=17801 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=skdump exe=/usr/sbin/skdump subj=system_u:system_r:abrt_t:s0-s0:c0.c1023 key=(null)

Hash: skdump,abrt_t,fixed_disk_device_t,blk_file,read

audit2allow

#============= abrt_t ==============
allow abrt_t fixed_disk_device_t:blk_file read;

audit2allow -R

#============= abrt_t ==============
allow abrt_t fixed_disk_device_t:blk_file read;
Comment 11 Daniel Walsh 2012-08-13 15:42:45 EDT
Why is abrt running skdump?
Comment 12 Fedora End Of Life 2013-01-16 04:53:22 EST
This message is a reminder that Fedora 16 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 16. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '16'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 16's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 16 is 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" 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
Comment 13 Fedora End Of Life 2013-02-13 02:53:13 EST
Fedora 16 changed to end-of-life (EOL) status on 2013-02-12. Fedora 16 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.
Comment 14 Daniel Walsh 2013-06-27 15:08:07 EDT
*** Bug 977946 has been marked as a duplicate of this bug. ***
Comment 15 Igor Gnatenko 2013-09-01 02:46:07 EDT
Description of problem:
Steps to reproduce:
1. Open disks
2. Open usb flash (sdb in my case)
3. Click button 'Settings'
4. Click button 'Restore disk image'
5. Start download .iso at browser (chrome in my case)
6. Open downloads folder in dialog at disks
7. Wait for complete download
8. Selinux alert

Additional info:
reporter:       libreport-2.1.6
hashmarkername: setroubleshoot
kernel:         3.10.10-200.fc19.x86_64
type:           libreport
Comment 16 汪明衡 2013-09-24 10:54:55 EDT
Description of problem:
I'm clear what the problem is.However,I just removed a usb device (kindle paperwhite) through 'Disks'.I clicked 'poweroff',then it showed 'No Media',but the device remained there.So I clicked poweroff again,and Disks crashed.After about one minute,these windows appeared.

Additional info:
reporter:       libreport-2.1.7
hashmarkername: setroubleshoot
kernel:         3.11.1-200.fc19.x86_64
type:           libreport
Comment 17 汪明衡 2013-09-24 11:02:23 EDT
(In reply to 汪明衡 from comment #16)
> Description of problem:
> I'm not clear what the problem is.However,I just removed a usb device (kindle
> paperwhite) through 'Disks'.I clicked 'poweroff',then it showed 'No
> Media',but the device remained there.So I clicked poweroff again,and Disks
> crashed.After about one minute,these windows appeared.
> 
> Additional info:
> reporter:       libreport-2.1.7
> hashmarkername: setroubleshoot
> kernel:         3.11.1-200.fc19.x86_64
> type:           libreport

1) Clicked 'poweroff' in Disks for my Kindle paperwhite.
2) Clicked 'poweroff' again because my kindle was still there showing 'No media'.
2) SELinux alerted.
Comment 18 Michal Nowak 2013-11-02 11:03:38 EDT
Description of problem:
GNOME Disks crashed ABRT tried to play with it's core but it failed:

--- Running report_uReport ---
Unable to open './core_backtrace': Permission denied.
reporter-ureport failed with exit code 1
('report_uReport' exited with 1)

Then I got this AVC.

Additional info:
reporter:       libreport-2.1.9
hashmarkername: setroubleshoot
kernel:         3.11.6-200.fc19.x86_64
type:           libreport
Comment 19 Michal Nowak 2013-11-27 07:24:55 EST
Description of problem:
Started gnome disks with Sandisk Sansa Clip+ attached.

Additional info:
reporter:       libreport-2.1.9
hashmarkername: setroubleshoot
kernel:         3.11.9-200.fc19.x86_64
type:           libreport
Comment 20 NickG 2013-11-30 04:30:58 EST
Description of problem:
Tried ejecting a drive that the gnome-disks left showing as present after removal from the system.
Clicked the power off button for the drive hoping to find a way to remove it and instead the app crashed with an selinux notification.


Additional info:
reporter:       libreport-2.1.9
hashmarkername: setroubleshoot
kernel:         3.11.8-200.fc19.i686
type:           libreport
Comment 21 David Strauss 2013-12-06 11:43:08 EST
Description of problem:
Tried to create a FAT file system on a thumb drive.

Additional info:
reporter:       libreport-2.1.9
hashmarkername: setroubleshoot
kernel:         3.11.9-200.fc19.x86_64
type:           libreport
Comment 22 Laurent Rineau 2014-03-10 08:54:35 EDT
Description of problem:
I was using "Disks", from Gnome, and it crashed. I got a report from abrt and setroubleshot at the same time.

Additional info:
reporter:       libreport-2.1.12
hashmarkername: setroubleshoot
kernel:         3.13.5-101.fc19.x86_64
type:           libreport
Comment 23 Fedora End Of Life 2015-01-09 16:56:40 EST
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

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

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is 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  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

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.
Comment 24 Fedora End Of Life 2015-02-18 08:42:04 EST
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

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