Bug 977199 - SELinux is preventing /usr/lib64/xulrunner/plugin-container from 'read' accesses on the file /home/a320750/.mozilla/firefox/kceigv7o.default/prefs.js.
SELinux is preventing /usr/lib64/xulrunner/plugin-container from 'read' acces...
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
18
x86_64 Linux
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
abrt_hash:72511ada9731d6c8dc54cbb2984...
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-06-24 00:04 EDT by fbellio
Modified: 2013-10-07 07:59 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-06-24 05:37:14 EDT
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 fbellio 2013-06-24 00:04:04 EDT
Description of problem:
When gnome session is opened
SELinux is preventing /usr/lib64/xulrunner/plugin-container from 'read' accesses on the file /home/a320750/.mozilla/firefox/kceigv7o.default/prefs.js.

*****  Plugin restorecon (57.3 confidence) suggests  *************************

If you want to fix the label. 
/home/a320750/.mozilla/firefox/kceigv7o.default/prefs.js default label should be mozilla_home_t.
Then you can run restorecon.
Do
# /sbin/restorecon -v /home/a320750/.mozilla/firefox/kceigv7o.default/prefs.js

*****  Plugin mozplugger (43.1 confidence) suggests  *************************

If you want to use the plugin package
Then you must turn off SELinux controls on the Firefox plugins.
Do
# setsebool unconfined_mozilla_plugin_transition 0

*****  Plugin catchall (1.06 confidence) suggests  ***************************

If you believe that plugin-container should be allowed read access on the prefs.js 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 plugin-containe /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:home_root_t:s0
Target Objects                /home/a320750/.mozilla/firefox/kceigv7o.default/pr
                              efs.js [ file ]
Source                        plugin-containe
Source Path                   /usr/lib64/xulrunner/plugin-container
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           xulrunner-21.0-4.fc18.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.11.1-97.fc18.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.9.6-200.fc18.x86_64 #1 SMP Thu
                              Jun 13 18:56:55 UTC 2013 x86_64 x86_64
Alert Count                   3
First Seen                    2013-06-24 05:56:36 CEST
Last Seen                     2013-06-24 05:56:57 CEST
Local ID                      2953e880-5f54-4559-967e-08f7642077b2

Raw Audit Messages
type=AVC msg=audit(1372046217.40:390): avc:  denied  { read } for  pid=2416 comm="plugin-containe" name="prefs.js" dev="dm-2" ino=2625049 scontext=unconfined_u:unconfined_r:mozilla_plugin_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:home_root_t:s0 tclass=file


type=SYSCALL msg=audit(1372046217.40:390): arch=x86_64 syscall=open success=no exit=EACCES a0=7f9cdb7c6040 a1=0 a2=39 a3=7f9cdb7c6000 items=0 ppid=2319 pid=2416 auid=1000 uid=1000 gid=1000 euid=1000 suid=1000 fsuid=1000 egid=1000 sgid=1000 fsgid=1000 ses=2 tty=(none) comm=plugin-containe exe=/usr/lib64/xulrunner/plugin-container subj=unconfined_u:unconfined_r:mozilla_plugin_t:s0-s0:c0.c1023 key=(null)

Hash: plugin-containe,mozilla_plugin_t,home_root_t,file,read

audit2allow

#============= mozilla_plugin_t ==============
allow mozilla_plugin_t home_root_t:file read;

audit2allow -R
require {
	type home_root_t;
	type mozilla_plugin_t;
	class file read;
}

#============= mozilla_plugin_t ==============
allow mozilla_plugin_t home_root_t:file read;


Additional info:
reporter:       libreport-2.1.4
hashmarkername: setroubleshoot
kernel:         3.9.6-200.fc18.x86_64
type:           libreport
Comment 1 Miroslav Grepl 2013-06-24 05:37:14 EDT
The alert tells you what to do.

# /sbin/restorecon -v /home/a320750/.mozilla/firefox/kceigv7o.default/prefs.js

Probably you will need to run

# restorecon -R -v /home/a320750/.mozilla

in your terminal.

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