Bug 449045 - selinux-policy-targeted 3.3.1-55 prevents httpd from starting with non-standard DocumentRoot
selinux-policy-targeted 3.3.1-55 prevents httpd from starting with non-standa...
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: selinux-policy-targeted (Show other bugs)
9
All Linux
low Severity low
: ---
: ---
Assigned To: Daniel Walsh
Ben Levenson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-05-29 20:49 EDT by Peter Blomgren
Modified: 2008-05-30 08:49 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-05-30 08:49:47 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 Peter Blomgren 2008-05-29 20:49:09 EDT
Description of problem:
Start of httpd fails with message

Starting httpd: Syntax error on line 280 of /etc/httpd/conf/httpd.conf:
DocumentRoot must be a directory


Version-Release number of selected component (if applicable):
selinux-policy-targeted-3.3.1-55.fc9.noarch

How reproducible:
Always

Steps to Reproduce:
1. service httpd start
2.
3.
  
Actual results:
Starting httpd: Syntax error on line 280 of /etc/httpd/conf/httpd.conf:
DocumentRoot must be a directory


Expected results:
httpd starts

Additional info:
Line#280 is:
DocumentRoot "/home/myself/SYNC/public_html"

Raw Audit Messages:

host=[xxx] type=AVC msg=audit(1212108073.443:35): avc: denied { search } for
pid=4701 comm="httpd" name="SYNC" dev=sda8 ino=6398195
scontext=unconfined_u:system_r:httpd_t:s0
tcontext=unconfined_u:object_r:user_home_t:s0 tclass=dir 

host=[xxx] type=SYSCALL msg=audit(1212108073.443:35): arch=c000003e syscall=4
success=no exit=-13 a0=7fbac939c218 a1=7fffd0b7b300 a2=7fffd0b7b300 a3=c items=0
ppid=4700 pid=4701 auid=500 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0
fsgid=0 tty=pts1 ses=1 comm="httpd" exe="/usr/sbin/httpd"
subj=unconfined_u:system_r:httpd_t:s0 key=(null)
Comment 1 Daniel Walsh 2008-05-30 08:49:47 EDT
If you customize the settings on your machine, you also need to customize the
SELinux settings.  

Turn on the SELinux Boolean

setsebool -P httpd_enable_homedirs 1

Fix your labeleing

# semanage fcontext -a -t httpd_sys_content_t '/home/myself/SYNC/public_html(/.*)?'
# restorecon -R -v /home/myself/SYNC/public_html

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