RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1165058 - System-Update/avc shows avc error messages while doing TPS testing.
Summary: System-Update/avc shows avc error messages while doing TPS testing.
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: selinux-policy
Version: 7.1
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: rc
: ---
Assignee: Miroslav Grepl
QA Contact: Milos Malik
URL:
Whiteboard:
Depends On:
Blocks: 1166674
TreeView+ depends on / blocked
 
Reported: 2014-11-18 08:55 UTC by Amita Sharma
Modified: 2023-09-14 02:51 UTC (History)
8 users (show)

Fixed In Version: selinux-policy-3.13.1-11.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-03-05 10:47:08 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:0458 0 normal SHIPPED_LIVE selinux-policy bug fix and enhancement update 2015-03-05 15:17:00 UTC

Description Amita Sharma 2014-11-18 08:55:12 UTC
Description of problem:
System-Update/avc  shows avc error messages while doing TPS testing.

Version-Release number of selected component (if applicable):
Running 'rpm -q selinux-policy || true'
selinux-policy-3.12.1-153.el7_0.11.noarch

How reproducible:
Always

Steps to Reproduce:
Executing TPS tests for errata :: https://errata.devel.redhat.com/tps/errata_results/21326

Actual results:
AVC error messages ::
====================
Info: Searching AVC errors produced since 1416293863.06 (Tue Nov 18 01:57:43 2014)
Searching logs...
Running '/usr/bin/env LC_ALL=en_US.UTF-8 /sbin/ausearch -m AVC -m USER_AVC -m SELINUX_ERR -ts 11/18/2014 01:57:43 < /dev/null >/mnt/testarea/tmp.rhts-db-submit-result.N_JVVW 2>&1'
----
time->Tue Nov 18 02:03:49 2014
type=USER_AVC msg=audit(1416294229.397:79): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='avc:  received policyload notice (seqno=2)  exe="/usr/lib/systemd/systemd" sauid=0 hostname=? addr=? terminal=?'
----
time->Tue Nov 18 02:03:46 2014
type=SYSCALL msg=audit(1416294226.434:78): arch=c000003e syscall=59 success=yes exit=0 a0=11db560 a1=11da740 a2=11d9400 a3=7fff90abe820 items=0 ppid=29934 pid=29935 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="newaliases" exe="/usr/sbin/sendmail.postfix" subj=unconfined_u:system_r:system_mail_t:s0-s0:c0.c1023 key=(null)
type=AVC msg=audit(1416294226.434:78): avc:  denied  { read } for  pid=29935 comm="newaliases" path="/tmp/tmp.7k6C3Huf9e" dev="dm-0" ino=202060480 scontext=unconfined_u:system_r:system_mail_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=dir
type=AVC msg=audit(1416294226.434:78): avc:  denied  { read } for  pid=29935 comm="newaliases" path="/tmp/tmp.7k6C3Huf9e" dev="dm-0" ino=202060480 scontext=unconfined_u:system_r:system_mail_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=dir
Fail: AVC messages found.
Checking for errors...
Using stronger AVC checks.
	Define empty RHTS_OPTION_STRONGER_AVC parameter if this causes any problems.
Running 'cat /mnt/testarea/tmp.rhts-db-submit-result.N_JVVW | /sbin/ausearch -m AVC -m SELINUX_ERR'
Fail: AVC messages found.
Running 'cat %s | /sbin/ausearch -m USER_AVC >/mnt/testarea/tmp.rhts-db-submit-result.2_AryP 2>&1'
Info: No AVC messages found.
/bin/grep 'avc: ' /mnt/testarea/dmesg.log | /bin/grep --invert-match TESTOUT.log
No AVC messages found in dmesg
Running '/usr/sbin/sestatus'
SELinux status:                 enabled
SELinuxfs mount:                /sys/fs/selinux
SELinux root directory:         /etc/selinux
Loaded policy name:             targeted
Current mode:                   enforcing
Mode from config file:          enforcing
Policy MLS status:              enabled
Policy deny_unknown status:     allowed
Max kernel policy version:      28
Running 'rpm -q selinux-policy || true'
selinux-policy-3.12.1-153.el7_0.11.noarch


Expected results:
No AVC error message should show up.

Additional info:
This happened for all 4 variants.

Comment 2 Miroslav Grepl 2014-11-18 09:11:11 UTC
Is this a part of this test? I mean newaliases wants to access /tmp/tmp.7k6C3Huf9e?

Comment 3 Iveta Wiedermann 2014-11-18 15:34:19 UTC
I probably hit the same issue today:

time->Tue Nov 18 15:38:02 2014
type=SYSCALL msg=audit(1416321482.211:51): arch=c000003e syscall=59 success=yes exit=0 a0=a4d570 a1=a4c7a0 a2=a4b430 a3=7fff8748acf0 items=0 ppid=19639 pid=19640 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=51 sgid=51 fsgid=51 tty=(none) ses=4294967295 comm="newaliases" exe="/usr/sbin/sendmail.sendmail" subj=unconfined_u:system_r:system_mail_t:s0-s0:c0.c1023 key=(null)
type=AVC msg=audit(1416321482.211:51): avc:  denied  { read } for  pid=19640 comm="newaliases" path="/tmp/tmp.1gcBsNv09m" dev="dm-1" ino=202462602 scontext=unconfined_u:system_r:system_mail_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=dir
type=AVC msg=audit(1416321482.211:51): avc:  denied  { read } for  pid=19640 comm="newaliases" path="/tmp/tmp.1gcBsNv09m" dev="dm-1" ino=202462602 scontext=unconfined_u:system_r:system_mail_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=dir

It happened during  System-Update as well.

Comment 4 Miroslav Grepl 2014-11-21 11:43:05 UTC
It looks like a leak. Do you know who creates /tmp/tmp.7k6C3Huf9e?

Comment 5 Miroslav Grepl 2014-11-24 09:53:42 UTC
commit 3a80f06682910715e5bd14cafabb726cad6a7f8f
Author: Miroslav Grepl <mgrepl>
Date:   Mon Nov 24 10:53:14 2014 +0100

    Dontaudit list user_tmp files for system_mail_t.

Comment 10 errata-xmlrpc 2015-03-05 10:47:08 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-0458.html

Comment 11 Red Hat Bugzilla 2023-09-14 02:51:00 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 1000 days


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