Bug 1403445 - SELinux is preventing httpd from 'write' accesses on the directory /var/www/html/gocareera/wp-includes.
Summary: SELinux is preventing httpd from 'write' accesses on the directory /var/www/h...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 24
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Lukas Vrabec
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:7d83f26cce0b3eee53a7fa2e75a...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-12-10 11:43 UTC by Dmitrtiy
Modified: 2016-12-10 12:49 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-12-10 12:49:41 UTC
Type: ---


Attachments (Terms of Use)

Description Dmitrtiy 2016-12-10 11:43:54 UTC
Description of problem:
SELinux is preventing httpd from 'write' accesses on the directory /var/www/html/gocareera/wp-includes.

*****  Plugin httpd_write_content (92.2 confidence) suggests   ***************

If you want to allow httpd to have write access on the wp-includes directory
Then необходимо изменить метку на «/var/www/html/gocareera/wp-includes»
Do
# semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/gocareera/wp-includes'
# restorecon -v '/var/www/html/gocareera/wp-includes'

*****  Plugin catchall_boolean (7.83 confidence) suggests   ******************

If вы хотите выполнить следующее: allow httpd to unified
Then вы должны сообщить SELinux об этом, включив переключатель «httpd_unified».
Дополнительная документация на 'None' ман странице.
Do
setsebool -P httpd_unified 1

*****  Plugin catchall (1.41 confidence) suggests   **************************

If вы считаете, что httpd следует разрешить доступ write к wp-includes directory по умолчанию.
Then рекомендуется создать отчет об ошибке.
Чтобы разрешить доступ, можно создать локальный модуль политики.
Do
allow this access for now by executing:
# ausearch -c 'httpd' --raw | audit2allow -M my-httpd
# semodule -X 300 -i my-httpd.pp

Additional Information:
Source Context                system_u:system_r:httpd_t:s0
Target Context                unconfined_u:object_r:httpd_sys_content_t:s0
Target Objects                /var/www/html/gocareera/wp-includes [ dir ]
Source                        httpd
Source Path                   httpd
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-191.21.fc24.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 4.8.10-200.fc24.x86_64 #1 SMP Mon
                              Nov 21 17:55:46 UTC 2016 x86_64 x86_64
Alert Count                   27
First Seen                    2016-12-06 23:42:40 MSK
Last Seen                     2016-12-09 21:24:12 MSK
Local ID                      f6d5fa35-36cc-4fb3-b5fd-21b91b40bd66

Raw Audit Messages
type=AVC msg=audit(1481307852.837:375): avc:  denied  { write } for  pid=27697 comm="httpd" name="wp-includes" dev="sda8" ino=6040441 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:httpd_sys_content_t:s0 tclass=dir permissive=0


Hash: httpd,httpd_t,httpd_sys_content_t,dir,write

Version-Release number of selected component:
selinux-policy-3.13.1-191.21.fc24.noarch

Additional info:
reporter:       libreport-2.7.2
hashmarkername: setroubleshoot
kernel:         4.8.10-200.fc24.x86_64
type:           libreport

Potential duplicate: bug 901356

Comment 1 Daniel Walsh 2016-12-10 12:49:41 UTC
Alert tells  you what to do.

Description of problem:
SELinux is preventing httpd from 'write' accesses on the directory /var/www/html/gocareera/wp-includes.

*****  Plugin httpd_write_content (92.2 confidence) suggests   ***************

If you want to allow httpd to have write access on the wp-includes directory
Then необходимо изменить метку на «/var/www/html/gocareera/wp-includes»
Do
# semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/gocareera/wp-includes'
# restorecon -v '/var/www/html/gocareera/wp-includes'


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