Bug 909548 - SELinux is preventing /usr/bin/python2.7 from 'name_connect' accesses on the tcp_socket .
Summary: SELinux is preventing /usr/bin/python2.7 from 'name_connect' accesses on the ...
Keywords:
Status: CLOSED DUPLICATE of bug 909547
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 18
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:d3b765820f374d88267283ba00c...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-02-09 10:14 UTC by Niki Guldbrand
Modified: 2013-02-11 11:42 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-02-11 11:42:44 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 909539 0 unspecified CLOSED SELinux is preventing /usr/bin/python2.7 from 'name_connect' accesses on the tcp_socket . 2021-02-22 00:41:40 UTC

Internal Links: 909539

Description Niki Guldbrand 2013-02-09 10:14:19 UTC
Description of problem:
Trying to connect glance to a PostgreSQL backend
SELinux is preventing /usr/bin/python2.7 from 'name_connect' accesses on the tcp_socket .

*****  Plugin catchall (100. confidence) suggests  ***************************

If you believe that python2.7 should be allowed name_connect 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 glance-registry /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:glance_registry_t:s0
Target Context                system_u:object_r:postgresql_port_t:s0
Target Objects                 [ tcp_socket ]
Source                        glance-registry
Source Path                   /usr/bin/python2.7
Port                          5432
Host                          (removed)
Source RPM Packages           python-2.7.3-13.fc18.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.11.1-74.fc18.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.7.5-201.fc18.x86_64 #1 SMP Mon
                              Jan 28 19:54:41 UTC 2013 x86_64 x86_64
Alert Count                   344
First Seen                    2013-02-09 11:08:48 CET
Last Seen                     2013-02-09 11:16:54 CET
Local ID                      b9125a74-b768-444d-b006-c1f8a2ad5805

Raw Audit Messages
type=AVC msg=audit(1360405014.175:1676): avc:  denied  { name_connect } for  pid=20259 comm="glance-registry" dest=5432 scontext=system_u:system_r:glance_registry_t:s0 tcontext=system_u:object_r:postgresql_port_t:s0 tclass=tcp_socket


type=SYSCALL msg=audit(1360405014.175:1676): arch=x86_64 syscall=connect success=no exit=EACCES a0=5 a1=34b4710 a2=10 a3=7fff67132724 items=0 ppid=14959 pid=20259 auid=4294967295 uid=161 gid=161 euid=161 suid=161 fsuid=161 egid=161 sgid=161 fsgid=161 ses=4294967295 tty=(none) comm=glance-registry exe=/usr/bin/python2.7 subj=system_u:system_r:glance_registry_t:s0 key=(null)

Hash: glance-registry,glance_registry_t,postgresql_port_t,tcp_socket,name_connect

audit2allow

#============= glance_registry_t ==============
allow glance_registry_t postgresql_port_t:tcp_socket name_connect;

audit2allow -R

#============= glance_registry_t ==============
allow glance_registry_t postgresql_port_t:tcp_socket name_connect;


Additional info:
hashmarkername: setroubleshoot
kernel:         3.7.5-201.fc18.x86_64
type:           libreport

Comment 1 Miroslav Grepl 2013-02-11 11:42:44 UTC

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


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