Bug 830634 - SELinux is preventing /usr/libexec/totem-plugin-viewer from 'rmdir' accesses on the directory /home/ksugawar/.nv/GLCache/7627299e856060b7a1cf3345db62a833.
Summary: SELinux is preventing /usr/libexec/totem-plugin-viewer from 'rmdir' accesses ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 17
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:c1da596be3825fa78d38227e87c...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-06-11 04:03 UTC by Ken Sugawara
Modified: 2012-11-26 15:54 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-06-17 00:04:28 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
File: description (2.82 KB, text/plain)
2012-06-11 04:03 UTC, Ken Sugawara
no flags Details

Description Ken Sugawara 2012-06-11 04:03:29 UTC
libreport version: 2.0.10
executable:     /usr/bin/python2.7
hashmarkername: setroubleshoot
kernel:         3.4.0-1.fc17.x86_64
time:           2012年06月11日 13時02分21秒

description:    Binary file, 2892 bytes

Comment 1 Ken Sugawara 2012-06-11 04:03:32 UTC
Created attachment 590811 [details]
File: description

Comment 2 Miroslav Grepl 2012-06-11 09:14:51 UTC
Try to execute

chcon -R -t cache_home_t /home/ksugawar/.nv

Fixed in selinux-policy-3.10.0-130.fc17

Comment 3 Fedora Update System 2012-06-11 21:02:32 UTC
selinux-policy-3.10.0-130.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/selinux-policy-3.10.0-130.fc17

Comment 4 Fedora Update System 2012-06-15 23:59:31 UTC
Package selinux-policy-3.10.0-130.fc17:
* should fix your issue,
* was pushed to the Fedora 17 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing selinux-policy-3.10.0-130.fc17'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-9520/selinux-policy-3.10.0-130.fc17
then log in and leave karma (feedback).

Comment 5 Fedora Update System 2012-06-17 00:04:28 UTC
selinux-policy-3.10.0-130.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 6 Frédéric 2012-11-18 20:31:11 UTC
I have this issue with an up-to-date Fedora 17 (I regularly perform yum update). Why? Cannot open .mp3 files from firefox (16.0.2).

Comment 7 Miroslav Grepl 2012-11-19 10:14:38 UTC
what does

# ls -dZ /home/ksugawar/.nv

# matchpathcon /home/ksugawar/.nv

Comment 8 Frédéric 2012-11-19 18:43:14 UTC
> what does
> # ls -dZ /home/ksugawar/.nv

drwx------. fred fred unconfined_u:object_r:cache_home_t:s0 /home/fred/.nv/

# matchpathcon /home/ksugawar/.nv

/home/fred/.nv	unconfined_u:object_r:cache_home_t:s0

Comment 9 Miroslav Grepl 2012-11-26 15:47:38 UTC
Which is correct. Are you still getting this issue?

Comment 10 Frédéric 2012-11-26 15:54:50 UTC
Yes. But maybe it is just that I do not understand what to do when SELinux is complaining. I admit that it is a bit obscure to me. Here is the full report of SELinux, does it help?

SELinux is preventing /usr/libexec/totem-plugin-viewer from rmdir access on the directory /home/fred/.nv/GLCache/ec60e4935cf086521f038c12e69f37c0.

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

If you want to fix the label. 
/home/fred/.nv/GLCache/ec60e4935cf086521f038c12e69f37c0 default label should be cache_home_t.
Then you can run restorecon.
Do
# /sbin/restorecon -v /home/fred/.nv/GLCache/ec60e4935cf086521f038c12e69f37c0

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

If you believe that totem-plugin-viewer should be allowed rmdir access on the ec60e4935cf086521f038c12e69f37c0 directory 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 totem-plugin-vi /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                unconfined_u:unconfined_r:mozilla_plugin_t:s0-s0:c
                              0.c1023
Target Context                unconfined_u:object_r:user_home_t:s0
Target Objects                /home/fred/.nv/GLCache/ec60e4935cf086521f038c12e69
                              f37c0 [ dir ]
Source                        totem-plugin-vi
Source Path                   /usr/libexec/totem-plugin-viewer
Port                          <Inconnu>
Host                          casalibus
Source RPM Packages           totem-mozplugin-3.4.3-1.fc17.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.10.0-161.fc17.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     casalibus
Platform                      Linux casalibus 3.6.7-4.fc17.x86_64 #1 SMP Tue Nov
                              20 19:40:01 UTC 2012 x86_64 x86_64
Alert Count                   3
First Seen                    2012-11-26 16:50:00 CET
Last Seen                     2012-11-26 16:52:47 CET
Local ID                      e8ef4571-c5ad-4e1c-9880-6eebf2df9030

Raw Audit Messages
type=AVC msg=audit(1353945167.814:235): avc:  denied  { rmdir } for  pid=24369 comm="totem-plugin-vi" name="ec60e4935cf086521f038c12e69f37c0" dev="sdb1" ino=15991468 scontext=unconfined_u:unconfined_r:mozilla_plugin_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=dir


type=SYSCALL msg=audit(1353945167.814:235): arch=x86_64 syscall=rmdir success=no exit=EACCES a0=7fff6ceed570 a1=7fff6ceed570 a2=15 a3=5 items=0 ppid=1 pid=24369 auid=1000 uid=1000 gid=1000 euid=1000 suid=1000 fsuid=1000 egid=1000 sgid=1000 fsgid=1000 tty=(none) ses=2 comm=totem-plugin-vi exe=/usr/libexec/totem-plugin-viewer subj=unconfined_u:unconfined_r:mozilla_plugin_t:s0-s0:c0.c1023 key=(null)

Hash: totem-plugin-vi,mozilla_plugin_t,user_home_t,dir,rmdir

audit2allow

#============= mozilla_plugin_t ==============
allow mozilla_plugin_t user_home_t:dir rmdir;

audit2allow -R

#============= mozilla_plugin_t ==============
allow mozilla_plugin_t user_home_t:dir rmdir;


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