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 1379371 - AVCs when restarting pmlogger
Summary: AVCs when restarting pmlogger
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: selinux-policy
Version: 7.4
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Lukas Vrabec
QA Contact: Jan Zarsky
URL:
Whiteboard:
Depends On:
Blocks: 1420851
TreeView+ depends on / blocked
 
Reported: 2016-09-26 13:42 UTC by Jan Zarsky
Modified: 2020-09-10 09:48 UTC (History)
7 users (show)

Fixed In Version: selinux-policy-3.13.1-137
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-08-01 15:15:11 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:1861 0 normal SHIPPED_LIVE selinux-policy bug fix update 2017-08-01 17:50:24 UTC

Description Jan Zarsky 2016-09-26 13:42:42 UTC
Description of problem:
When restarting pmlogger service, there are AVCs, but everything seems to work.

Version-Release number of selected component (if applicable):
selinux-policy-3.13.1-100.el7.noarch
pcp-3.11.3-4.el7.x86_64

Steps to Reproduce:
1. # yum install pcp
2. # systemctl start pmcd pmlogger
3. # systemctl restart pmlogger

Actual results:
# ausearch -m avc
----
time->Mon Sep 26 09:34:55 2016
type=SYSCALL msg=audit(1474896895.884:307): arch=c000003e syscall=62 success=no exit=-1 a0=69ab a1=f a2=0 a3=7ffe6cba8b50 items=0 ppid=27103 pid=27126 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="pmsignal" exe="/usr/bin/bash" subj=system_u:system_r:pcp_pmlogger_t:s0 key=(null)
type=AVC msg=audit(1474896895.884:307): avc:  denied  { kill } for  pid=27126 comm="pmsignal" capability=5  scontext=system_u:system_r:pcp_pmlogger_t:s0 tcontext=system_u:system_r:pcp_pmlogger_t:s0 tclass=capability

Expected results:
no AVCs

Additional info:
When I run '/usr/share/pcp/lib/pmlogger' manually, there are no AVCs:
# cat /usr/lib/systemd/system/pmlogger.service 
...
[Service]
Type=oneshot
ExecStart=/usr/share/pcp/lib/pmlogger start
ExecStop=/usr/share/pcp/lib/pmlogger stop
RemainAfterExit=yes
...
# /usr/share/pcp/lib/pmlogger start
# /usr/share/pcp/lib/pmlogger stop
# ausearch -m avc
<no matches>

Comment 1 Milos Malik 2016-09-27 18:05:26 UTC
# rpm -qa selinux\*
selinux-policy-targeted-3.13.1-101.el7.noarch
selinux-policy-3.13.1-101.el7.noarch
#
----
type=USER_AVC msg=audit(09/27/2016 13:57:43.245:271) : pid=1 uid=root auid=unset ses=unset subj=system_u:system_r:init_t:s0 msg='avc:  denied  { status } for auid=root uid=root gid=root cmdline="systemctl is-enabled pmlogger.service" scontext=system_u:system_r:pcp_pmlogger_t:s0 tcontext=system_u:system_r:init_t:s0 tclass=system  exe=/usr/lib/systemd/systemd sauid=root hostname=? addr=? terminal=?' 
----
type=USER_AVC msg=audit(09/27/2016 13:57:43.247:272) : pid=1 uid=root auid=unset ses=unset subj=system_u:system_r:init_t:s0 msg='avc:  denied  { status } for auid=root uid=root gid=root cmdline="systemctl -q is-enabled pmlogger.service" scontext=system_u:system_r:pcp_pmlogger_t:s0 tcontext=system_u:system_r:init_t:s0 tclass=system  exe=/usr/lib/systemd/systemd sauid=root hostname=? addr=? terminal=?' 
----
type=SYSCALL msg=audit(09/27/2016 13:57:52.902:277) : arch=x86_64 syscall=connect success=no exit=EACCES(Permission denied) a0=0x3 a1=0x7f05a7786740 a2=0x6e a3=0x44 items=0 ppid=1632 pid=5682 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=logger exe=/usr/bin/logger subj=system_u:system_r:pcp_pmlogger_t:s0 key=(null) 
type=AVC msg=audit(09/27/2016 13:57:52.902:277) : avc:  denied  { write } for  pid=5682 comm=logger name=log dev="devtmpfs" ino=6846 scontext=system_u:system_r:pcp_pmlogger_t:s0 tcontext=system_u:object_r:devlog_t:s0 tclass=sock_file 
----
type=SYSCALL msg=audit(09/27/2016 14:02:11.458:301) : arch=x86_64 syscall=kill success=no exit=EACCES(Permission denied) a0=0x29d3 a1=SIGTERM a2=0x0 a3=0x7ffe74ef3d90 items=0 ppid=10784 pid=10832 auid=unset uid=root gid=root euid=root suid=root fsuid=root egid=root sgid=root fsgid=root tty=(none) ses=unset comm=pmsignal exe=/usr/bin/bash subj=system_u:system_r:pcp_pmlogger_t:s0 key=(null) 
type=AVC msg=audit(09/27/2016 14:02:11.458:301) : avc:  denied  { signal } for  pid=10832 comm=pmsignal scontext=system_u:system_r:pcp_pmlogger_t:s0 tcontext=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 tclass=process 
----

Comment 6 errata-xmlrpc 2017-08-01 15:15:11 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://access.redhat.com/errata/RHBA-2017:1861


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