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 1841829 - Fix for segfault with '-F' in iptables dumps
Summary: Fix for segfault with '-F' in iptables dumps
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: iptables
Version: 8.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: 8.3
Assignee: Phil Sutter
QA Contact: Jiri Peska
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-05-29 15:05 UTC by Phil Sutter
Modified: 2020-11-04 01:55 UTC (History)
2 users (show)

Fixed In Version: iptables-1.8.4-14.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-11-04 01:54:58 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2020:4518 0 None None None 2020-11-04 01:55:11 UTC

Description Phil Sutter 2020-05-29 15:05:26 UTC
When restoring a dump file containing '-F' (chain flush) commands, iptables-restore may segfault if a rule was added to that chain in the same dump before.

Fixed by upstream commit:

commit 5bd3ab5c778033877d44a0c619ef6f98f34516af
Author: Phil Sutter <phil>
Date:   Fri Apr 24 11:32:08 2020 +0200

    nft: Fix for '-F' in iptables dumps
    
    When restoring a dump which contains an explicit flush command,
    previously added rules are removed from cache and the following commit
    will try to create netlink messages based on freed memory.
    
    Fix this by weeding any rule-based commands from obj_list if they
    address the same chain.
    
    Signed-off-by: Phil Sutter <phil>

This commit adds a relevant testcase:

commit f2ace0cdf25a5911ac84015829d65d6050a5e82d
Author: Phil Sutter <phil>
Date:   Tue Apr 21 14:10:53 2020 +0200

    tests: shell: Test -F in dump files
    
    While not really useful, iptables-nft-restore shouldn't segfault either.
    This tests the problem described in nfbz#1407.
    
    Signed-off-by: Phil Sutter <phil>

Comment 6 errata-xmlrpc 2020-11-04 01:54:58 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 (iptables bug fix and enhancement update), 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-2020:4518


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