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 1243403 - avc: denied { read } for pid=22817 comm="iptables" name="xtables.lock" dev="tmpfs"
Summary: avc: denied { read } for pid=22817 comm="iptables" name="xtables.lock" dev...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: selinux-policy
Version: 7.2
Hardware: All
OS: Linux
high
unspecified
Target Milestone: rc
: ---
Assignee: Lukas Vrabec
QA Contact: Milos Malik
URL:
Whiteboard:
: 1247180 1260682 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-07-15 11:30 UTC by Kaushik Banerjee
Modified: 2015-11-19 10:40 UTC (History)
8 users (show)

Fixed In Version: selinux-policy-3.13.1-48.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-11-19 10:40:26 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:2300 0 normal SHIPPED_LIVE selinux-policy bug fix update 2015-11-19 09:55:26 UTC

Description Kaushik Banerjee 2015-07-15 11:30:19 UTC
Description of problem:
The beaker jobs (e.g. https://beaker.engineering.redhat.com/jobs/1014569) run on RHEL7.2 throws AVCs related to:

type=AVC msg=audit(1436945964.227:416): avc:  denied  { read } for  pid=22817 comm="iptables" name="xtables.lock" dev="tmpfs" ino=65562 scontext=system_u:system_r:iptables_t:s0 tcontext=system_u:object_r:var_run_t:s0 tclass=file

AND

type=AVC msg=audit(1436945964.326:430): avc:  denied  { read } for  pid=22841 comm="ip6tables" name="xtables.lock" dev="tmpfs" ino=65562 scontext=system_u:system_r:iptables_t:s0 tcontext=system_u:object_r:var_run_t:s0 tclass=file

Version-Release number of selected component (if applicable):
selinux-policy-3.13.1-30.el7.noarch

How reproducible:
Always

Comment 2 Lukas Vrabec 2015-07-15 11:53:50 UTC
Hi,
Where is "xtables.lock" stored?

Comment 3 Milos Malik 2015-07-15 12:21:17 UTC
# strings `which iptables` | grep lock
  --wait	-w [seconds]	wait for the xtables lock
Another app is currently holding the xtables lock. 
  --wait	-w [seconds]	wait for the xtables lock
/run/xtables.lock
Another app is currently holding the xtables lock; waiting (%ds) for it to exit...
flock
#

Comment 4 Miroslav Grepl 2015-08-04 15:38:43 UTC
Ok and do we know how it is created?

Comment 5 Milos Malik 2015-08-04 18:56:25 UTC
Either "service iptables restart" or "service network restart".

Comment 7 Miroslav Grepl 2015-08-07 09:59:27 UTC
*** Bug 1247180 has been marked as a duplicate of this bug. ***

Comment 10 Lukas Vrabec 2015-08-11 12:44:57 UTC
commit 6154c0648aecf0e8314a0bc94c5fe662c1ec67dc
Author: Lukas Vrabec <lvrabec>
Date:   Tue Aug 11 10:10:41 2015 +0200

    Label /var/run/xtables.* as iptables_var_run_t
    Resolves: #1243403

[root@dell-pem805-01 run]# sudo systemctl restart firewalld 
[root@dell-pem805-01 run]# sudo systemctl status firewalld 
● firewalld.service - firewalld - dynamic firewall daemon
   Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)
   Active: active (running) since Tue 2015-08-11 08:43:46 EDT; 7s ago
 Main PID: 29825 (firewalld)
   CGroup: /system.slice/firewalld.service
           └─29825 /usr/bin/python -Es /usr/sbin/firewalld --nofork --nopid

Aug 11 08:43:46 dell-pem805-01.rhts.eng.bos.redhat.com systemd[1]: Starting firewalld - dynamic firewall daemon...
Aug 11 08:43:46 dell-pem805-01.rhts.eng.bos.redhat.com systemd[1]: Started firewalld - dynamic firewall daemon.

[root@dell-pem805-01 run]# ls -Z /var/run/xtables.lock 
-rw-------. root root system_u:object_r:iptables_var_run_t:s0 /var/run/xtables.lock

Comment 20 Miroslav Grepl 2015-09-10 15:17:33 UTC
*** Bug 1260682 has been marked as a duplicate of this bug. ***

Comment 23 errata-xmlrpc 2015-11-19 10:40:26 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-2300.html


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