Bug 986385 - SELinux is preventing /usr/sbin/ldconfig from 'read' accesses on the chr_file /dev/urandom.
SELinux is preventing /usr/sbin/ldconfig from 'read' accesses on the chr_file...
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
19
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
abrt_hash:72f953c4daa182e3996a4a12aa3...
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-19 12:06 EDT by Kamil Páral
Modified: 2013-08-04 18:59 EDT (History)
3 users (show)

See Also:
Fixed In Version: selinux-policy-3.12.1-69.fc19
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-08-04 18:59:18 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 Kamil Páral 2013-07-19 12:06:19 EDT
Description of problem:
I resumed my computer and this popped up.
SELinux is preventing /usr/sbin/ldconfig from 'read' accesses on the chr_file /dev/urandom.

*****  Plugin catchall_boolean (89.3 confidence) suggests  *******************

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

*****  Plugin catchall (11.6 confidence) suggests  ***************************

If you believe that ldconfig should be allowed read access on the urandom chr_file 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 ldconfig /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:ldconfig_t:s0
Target Context                system_u:object_r:urandom_device_t:s0
Target Objects                /dev/urandom [ chr_file ]
Source                        ldconfig
Source Path                   /usr/sbin/ldconfig
Port                          <Neznámé>
Host                          (removed)
Source RPM Packages           glibc-2.17-11.fc19.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.12.1-65.fc19.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Permissive
Host Name                     (removed)
Platform                      Linux (removed) 3.9.9-302.fc19.x86_64 #1 SMP Sat
                              Jul 6 13:41:07 UTC 2013 x86_64 x86_64
Alert Count                   1
First Seen                    2013-07-19 18:04:57 CEST
Last Seen                     2013-07-19 18:04:57 CEST
Local ID                      f5f7c181-6c74-4578-a8cb-f293e2b67a3d

Raw Audit Messages
type=AVC msg=audit(1374249897.171:326): avc:  denied  { read } for  pid=8573 comm="ldconfig" path="/dev/urandom" dev="devtmpfs" ino=1033 scontext=system_u:system_r:ldconfig_t:s0 tcontext=system_u:object_r:urandom_device_t:s0 tclass=chr_file


type=SYSCALL msg=audit(1374249897.171:326): arch=x86_64 syscall=execve success=yes exit=0 a0=23d8b10 a1=23d8c10 a2=23d75f0 a3=0 items=0 ppid=8571 pid=8573 auid=4294967295 uid=1000 gid=1000 euid=1000 suid=1000 fsuid=1000 egid=1000 sgid=1000 fsgid=1000 ses=4294967295 tty=(none) comm=ldconfig exe=/usr/sbin/ldconfig subj=system_u:system_r:ldconfig_t:s0 key=(null)

Hash: ldconfig,ldconfig_t,urandom_device_t,chr_file,read

Additional info:
reporter:       libreport-2.1.5
hashmarkername: setroubleshoot
kernel:         3.9.9-302.fc19.x86_64
type:           libreport
Comment 1 Daniel Walsh 2013-07-21 07:02:01 EDT
This is s a leaked file descriptor.  Some tool had an open read fd to /dev/urandom and then executed ldconfig.

Added dontaudit rules for this into git.
c168faac729de9e68f46980b7f978d190c003462
Comment 2 Kamil Páral 2013-07-22 04:21:41 EDT
It seems that it is related to connecting to network. I see it on two different notebooks, after I resume and the network is re-connected, every time.
Comment 3 Daniel Walsh 2013-07-24 18:51:16 EDT
c168faac729de9e68f46980b7f978d190c003462 I just added dontaudit for all device nodes leaked into ldconfig, since this happens too frequently.
Comment 4 Fedora Update System 2013-08-02 09:28:25 EDT
selinux-policy-3.12.1-69.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/selinux-policy-3.12.1-69.fc19
Comment 5 Fedora Update System 2013-08-02 17:54:30 EDT
Package selinux-policy-3.12.1-69.fc19:
* should fix your issue,
* was pushed to the Fedora 19 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing selinux-policy-3.12.1-69.fc19'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-14089/selinux-policy-3.12.1-69.fc19
then log in and leave karma (feedback).
Comment 6 Fedora Update System 2013-08-04 18:59:18 EDT
selinux-policy-3.12.1-69.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.

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