Bug 1235852 - SELinux is preventing mysqld from 'name_connect' accesses on the tcp_socket port 443.
Summary: SELinux is preventing mysqld from 'name_connect' accesses on the tcp_socket p...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 22
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:f039d847f23b7a9210fab8ba113...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-06-25 22:28 UTC by Mikhail
Modified: 2015-06-26 08:49 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-06-26 08:49:29 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Mikhail 2015-06-25 22:28:30 UTC
Description of problem:
SELinux is preventing mysqld from 'name_connect' accesses on the tcp_socket port 443.

*****  Plugin catchall_boolean (47.5 confidence) suggests   ******************

If you want to allow nis to enabled
Then you must tell SELinux about this by enabling the 'nis_enabled' boolean.
You can read 'None' man page for more details.
Do
setsebool -P nis_enabled 1

*****  Plugin catchall_boolean (47.5 confidence) suggests   ******************

If you want to allow mysql to connect any
Then you must tell SELinux about this by enabling the 'mysql_connect_any' boolean.
You can read 'None' man page for more details.
Do
setsebool -P mysql_connect_any 1

*****  Plugin catchall (6.38 confidence) suggests   **************************

If you believe that mysqld should be allowed name_connect access on the port 443 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 mysqld /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:mysqld_t:s0
Target Context                system_u:object_r:http_port_t:s0
Target Objects                port 443 [ tcp_socket ]
Source                        mysqld
Source Path                   mysqld
Port                          443
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-128.2.fc22.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 4.0.6-300.fc22.x86_64+debug #1 SMP
                              Tue Jun 23 13:40:02 UTC 2015 x86_64 x86_64
Alert Count                   1
First Seen                    2015-06-26 03:28:05 YEKT
Last Seen                     2015-06-26 03:28:05 YEKT
Local ID                      c9411da8-89e6-4049-9393-1e8e4aeca5f5

Raw Audit Messages
type=AVC msg=audit(1435271285.794:854): avc:  denied  { name_connect } for  pid=31549 comm="mysqld" dest=443 scontext=system_u:system_r:mysqld_t:s0 tcontext=system_u:object_r:http_port_t:s0 tclass=tcp_socket permissive=0


Hash: mysqld,mysqld_t,http_port_t,tcp_socket,name_connect

Version-Release number of selected component:
selinux-policy-3.13.1-128.2.fc22.noarch

Additional info:
reporter:       libreport-2.6.0
hashmarkername: setroubleshoot
kernel:         4.0.6-300.fc22.x86_64+debug
type:           libreport

Comment 1 Lukas Vrabec 2015-06-26 08:49:29 UTC
*****  Plugin catchall_boolean (47.5 confidence) suggests   ******************

If you want to allow mysql to connect any
Then you must tell SELinux about this by enabling the 'mysql_connect_any' boolean.
You can read 'None' man page for more details.
Do
setsebool -P mysql_connect_any 1


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