Bug 868968 - SELinux is preventing /usr/sbin/httpd from 'name_bind' accesses on the tcp_socket .
Summary: SELinux is preventing /usr/sbin/httpd from 'name_bind' accesses on the tcp_so...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 18
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:9bd846cb324c678f9d483ef290a...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-10-22 15:23 UTC by Nikhil John
Modified: 2013-10-25 15:03 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-10-25 15:02:41 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
File: type (9 bytes, text/plain)
2012-10-22 15:23 UTC, Nikhil John
no flags Details
File: hashmarkername (14 bytes, text/plain)
2012-10-22 15:23 UTC, Nikhil John
no flags Details

Description Nikhil John 2012-10-22 15:23:35 UTC
Additional info:
libreport version: 2.0.16
kernel:         3.6.1-1.fc18.x86_64

description:
:SELinux is preventing /usr/sbin/httpd from 'name_bind' accesses on the tcp_socket .
:
:*****  Plugin catchall (100. confidence) suggests  ***************************
:
:If you believe that httpd should be allowed name_bind access on the  tcp_socket 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 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                system_u:object_r:mysqld_port_t:s0
:Target Objects                 [ tcp_socket ]
:Source                        httpd
:Source Path                   /usr/sbin/httpd
:Port                          3306
:Host                          (removed)
:Source RPM Packages           httpd-2.4.3-10.fc18.x86_64
:Target RPM Packages           
:Policy RPM                    selinux-policy-3.11.1-36.fc18.noarch
:Selinux Enabled               True
:Policy Type                   targeted
:Enforcing Mode                Enforcing
:Host Name                     (removed)
:Platform                      Linux (removed) 3.6.1-1.fc18.x86_64 #1 SMP Mon Oct
:                              8 17:19:09 UTC 2012 x86_64 x86_64
:Alert Count                   1
:First Seen                    2012-10-22 20:50:53 IST
:Last Seen                     2012-10-22 20:50:53 IST
:Local ID                      b7e5fadd-fd76-4c72-a6e6-7114a81f195c
:
:Raw Audit Messages
:type=AVC msg=audit(1350919253.686:446): avc:  denied  { name_bind } for  pid=6535 comm="httpd" src=3306 scontext=system_u:system_r:httpd_t:s0 tcontext=system_u:object_r:mysqld_port_t:s0 tclass=tcp_socket
:
:
:type=SYSCALL msg=audit(1350919253.686:446): arch=x86_64 syscall=bind success=no exit=EACCES a0=3 a1=7f7429ce7ce8 a2=10 a3=7fff11073af0 items=0 ppid=1 pid=6535 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=httpd exe=/usr/sbin/httpd subj=system_u:system_r:httpd_t:s0 key=(null)
:
:Hash: httpd,httpd_t,mysqld_port_t,tcp_socket,name_bind
:
:audit2allow
:
:#============= httpd_t ==============
:#!!!! This avc is allowed in the current policy
:
:allow httpd_t mysqld_port_t:tcp_socket name_bind;
:
:audit2allow -R
:
:#============= httpd_t ==============
:#!!!! This avc is allowed in the current policy
:
:allow httpd_t mysqld_port_t:tcp_socket name_bind;
:

Comment 1 Nikhil John 2012-10-22 15:23:39 UTC
Created attachment 631595 [details]
File: type

Comment 2 Nikhil John 2012-10-22 15:23:44 UTC
Created attachment 631596 [details]
File: hashmarkername

Comment 3 Daniel Walsh 2012-10-24 19:35:19 UTC
Why do you want apache to bind to a mysql port?

Comment 4 Nikhil John 2013-10-25 15:02:41 UTC
This was a very old post directed from the fedora bug reporting software. I dont have much idea of what this actually is. Also, as I use fedora 19, i didn't had any SE-Linux Policy issues with Apache or MySQL.


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