Bug 966315 - SELinux is preventing /usr/sbin/httpd from 'read' accesses on the file colchange.cgi.
SELinux is preventing /usr/sbin/httpd from 'read' accesses on the file colcha...
Status: CLOSED DUPLICATE of bug 966313
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2013-05-22 23:32 EDT by Moez Roy
Modified: 2013-05-23 04:16 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-05-23 04:16:33 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Moez Roy 2013-05-22 23:32:24 EDT
Description of problem:
SELinux is preventing /usr/sbin/httpd from 'read' accesses on the file colchange.cgi.

*****  Plugin catchall_boolean (89.3 confidence) suggests  *******************

If you want to allow httpd to read user content
Then you must tell SELinux about this by enabling the 'httpd_read_user_content' boolean.
You can read 'user_selinux' man page for more details.
setsebool -P httpd_read_user_content 1

*****  Plugin catchall (11.6 confidence) suggests  ***************************

If you believe that httpd should be allowed read access on the colchange.cgi file by default.
Then you should report this as a bug.
You can generate a local policy module to allow this access.
allow this access for now by executing:
# grep /usr/sbin/httpd /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:httpd_t:s0
Target Context                unconfined_u:object_r:user_home_t:s0
Target Objects                colchange.cgi [ file ]
Source                        /usr/sbin/httpd
Source Path                   /usr/sbin/httpd
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           httpd-2.4.4-3.fc18.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.11.1-96.fc18.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.9.2-200.fc18.x86_64 #1 SMP Mon
                              May 13 13:59:47 UTC 2013 x86_64 x86_64
Alert Count                   11
First Seen                    2013-05-22 20:30:13 PDT
Last Seen                     2013-05-22 20:30:14 PDT
Local ID                      df5ce1e8-a1ca-4e7b-b87b-75ac1e97b4f1

Raw Audit Messages
type=AVC msg=audit(1369279814.11:456): avc:  denied  { read } for  pid=2394 comm="/usr/sbin/httpd" name="colchange.cgi" dev="sda2" ino=1319059 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file

type=SYSCALL msg=audit(1369279814.11:456): arch=x86_64 syscall=open success=no exit=EACCES a0=7ff582268c08 a1=80000 a2=1b6 a3=7ff582268bd8 items=0 ppid=2389 pid=2394 auid=4294967295 uid=48 gid=48 euid=48 suid=48 fsuid=48 egid=48 sgid=48 fsgid=48 ses=4294967295 tty=(none) comm=/usr/sbin/httpd exe=/usr/sbin/httpd subj=system_u:system_r:httpd_t:s0 key=(null)

Hash: /usr/sbin/httpd,httpd_t,user_home_t,file,read


#============= httpd_t ==============
#!!!! This avc can be allowed using the boolean 'httpd_read_user_content'

allow httpd_t user_home_t:file read;

audit2allow -R
require {
	type httpd_t;

#============= httpd_t ==============

Additional info:
hashmarkername: setroubleshoot
kernel:         3.9.2-200.fc18.x86_64
type:           libreport
Comment 1 Miroslav Grepl 2013-05-23 04:16:33 EDT

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

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