Bug 918141 - SELinux is preventing /usr/libexec/fprintd from 'execute' accesses on the file /usr/bin/netstat.
Summary: SELinux is preventing /usr/libexec/fprintd from 'execute' accesses on the fil...
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: nss
Version: 18
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Elio Maldonado Batiz
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:8f2e7a7bffd040fb30e280de8d5...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-03-05 15:13 UTC by Przemek Klosowski
Modified: 2014-02-05 19:40 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-02-05 19:40:34 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Przemek Klosowski 2013-03-05 15:13:10 UTC
Description of problem:
Fresh install of Fedora 18 x86_64.
SElinux alert is popping when executing 'su' from user account
SELinux is preventing /usr/libexec/fprintd from 'execute' accesses on the file /usr/bin/netstat.

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

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

Additional Information:
Source Context                system_u:system_r:fprintd_t:s0-s0:c0.c1023
Target Context                system_u:object_r:bin_t:s0
Target Objects                /usr/bin/netstat [ file ]
Source                        fprintd
Source Path                   /usr/libexec/fprintd
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           fprintd-0.4.1-4.fc18.x86_64
Target RPM Packages           net-tools-2.0-0.2.20121106git.fc18.x86_64
Policy RPM                    selinux-policy-3.11.1-82.fc18.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.8.1-201.fc18.x86_64 #1 SMP Thu
                              Feb 28 19:23:08 UTC 2013 x86_64 x86_64
Alert Count                   23
First Seen                    2013-03-04 23:15:25 EST
Last Seen                     2013-03-05 10:00:28 EST
Local ID                      810ec115-e585-4ef7-8572-af370bece1ed

Raw Audit Messages
type=AVC msg=audit(1362495628.705:375): avc:  denied  { execute } for  pid=3478 comm="fprintd" name="netstat" dev="dm-1" ino=10493149 scontext=system_u:system_r:fprintd_t:s0-s0:c0.c1023 tcontext=system_u:object_r:bin_t:s0 tclass=file


type=SYSCALL msg=audit(1362495628.705:375): arch=x86_64 syscall=execve success=no exit=EACCES a0=7fff20c7d823 a1=7fff20c7d900 a2=1ad70f0 a3=3fb18871e0 items=0 ppid=3475 pid=3478 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 ses=4294967295 tty=(none) comm=fprintd exe=/usr/libexec/fprintd subj=system_u:system_r:fprintd_t:s0-s0:c0.c1023 key=(null)

Hash: fprintd,fprintd_t,bin_t,file,execute

audit2allow

#============= fprintd_t ==============
allow fprintd_t bin_t:file execute;

audit2allow -R

#============= fprintd_t ==============
allow fprintd_t bin_t:file execute;


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

Comment 1 Daniel Walsh 2013-03-05 16:22:18 UTC
Why is fprintd executing netstat?  Is this an attempt to get randomization?

Comment 2 Bastien Nocera 2013-03-05 16:59:28 UTC
(In reply to comment #1)
> Why is fprintd executing netstat?

It's not executing netstat itself.

Comment 3 Daniel Walsh 2013-03-05 19:15:24 UTC
Is it using nsslib?

Comment 4 Bastien Nocera 2013-03-06 10:44:49 UTC
(In reply to comment #3)
> Is it using nsslib?

libfprint's UrU4000 driver uses nss to decrypt some communications with the device.

Comment 5 Daniel Walsh 2013-03-06 16:52:32 UTC
Is nsslib using netstat again?

Comment 6 Elio Maldonado Batiz 2013-03-06 17:56:09 UTC
(In reply to comment #5)
> Is nsslib using netstat again?

[... NSS]$ It's used in mozilla/security/nss/lib/freebl/unix_rand.c and

AFAIKT it has never stopped doing so. Looking at the upstream changelog
[... freebl]$ cvs log unix_rand.c | grep netstat
Bug 174993, don't fork netstat if data has been gathered from /dev/urandom

Comment 7 Elio Maldonado Batiz 2013-03-06 18:11:49 UTC
But looking at the source file I see

 * Bug 174993: On platforms providing /dev/urandom, don't fork netstat
 * either, if data has been gathered successfully.
 */

#if defined(BSDI) || defined(FREEBSD) || defined(NETBSD) \
    || defined(OPENBSD) || defined(DARWIN) || defined(LINUX) \
    || defined(HPUX)
    if (bytes)
        return;
#endif

and LINUX is indeed defined
./mozilla/security/coreconf/Linux.mk:OS_CFLAGS		= $(STANDARDS_CFLAGS) $(DSO_CFLAGS) $(OS_REL_CFLAGS) $(ARCHFLAG) -Wall -Werror-implicit-function-declaration -Wno-switch -pipe -DLINUX -Dlinux -DHAVE_STRERROR

Comment 8 Fedora End Of Life 2013-12-21 11:53:12 UTC
This message is a reminder that Fedora 18 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 18. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '18'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 18's end of life.

Thank you for reporting this issue and we are sorry that we may not be 
able to fix it before Fedora 18 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior to Fedora 18's end of life.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 9 Fedora End Of Life 2014-02-05 19:40:34 UTC
Fedora 18 changed to end-of-life (EOL) status on 2014-01-14. Fedora 18 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


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