Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
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 1464897

Summary: "setfacl --restore" fails due to use of uninitialized memory
Product: Red Hat Enterprise Linux 6 Reporter: Oneata Mircea Teodor <toneata>
Component: aclAssignee: Kamil Dudka <kdudka>
Status: CLOSED ERRATA QA Contact: Martin Zelený <mzeleny>
Severity: high Docs Contact:
Priority: urgent    
Version: 6.9CC: fkrska, kdudka, ksrot, mkolaja, mzeleny, rmetrich, sct, szidek, toneata
Target Milestone: rcKeywords: EasyFix, Patch, ZStream
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: acl-2.2.49-7.el6_9.1 Doc Type: Bug Fix
Doc Text:
Cause: Heap-allocated memory was not initialized. Consequence: A spurious failure was thrown out of 'setfacl --restore' occasionally. Fix: An upstream patch has been applied on acl source code to initialize heap-allocated memory. Result: The spurious failure of 'setfacl --restore' does not occur any more.
Story Points: ---
Clone Of: 1451801 Environment:
Last Closed: 2017-08-22 17:28:39 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1451801    
Bug Blocks:    

Description Oneata Mircea Teodor 2017-06-26 08:28:12 UTC
This bug has been copied from bug #1451801 and has been proposed
to be backported to 6.9 z-stream (EUS).

Comment 5 Marc Muehlfeld 2017-07-05 11:05:20 UTC
Kamil, can you please provide me the Cause/Consequence/Fix/Result information in the Doc Text field? It helps me to prepare the problem description for the erratum. Thanks.

Comment 6 Kamil Dudka 2017-07-07 13:22:54 UTC
Done.  Sorry for the delay.

Comment 7 Martin Zelený 2017-07-17 14:08:26 UTC
Successfully verified by TJ#1957380.

Valgrind output
on old version:
==21935== Memcheck, a memory error detector
==21935== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al.
==21935== Using Valgrind-3.8.1 and LibVEX; rerun with -h for copyright info
==21935== Command: setfacl --restore testFile.txt
==21935== 
==21935== Conditional jump or move depends on uninitialised value(s)
==21935==    at 0x4032FA: do_set (do_set.c:317)
==21935==    by 0x4021A1: restore (setfacl.c:187)
==21935==    by 0x4029E4: main (setfacl.c:575)
==21935== 
==21935== 
==21935== HEAP SUMMARY:
==21935==     in use at exit: 0 bytes in 0 blocks
==21935==   total heap usage: 91 allocs, 91 frees, 12,982 bytes allocated
==21935== 
==21935== All heap blocks were freed -- no leaks are possible
==21935== 
==21935== For counts of detected and suppressed errors, rerun with: -v
==21935== Use --track-origins=yes to see where uninitialised values come from
==21935== ERROR SUMMARY: 2 errors from 1 contexts (suppressed: 8 from 6)

on new version:
==24193== Memcheck, a memory error detector
==24193== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al.
==24193== Using Valgrind-3.8.1 and LibVEX; rerun with -h for copyright info
==24193== Command: setfacl --restore testFile.txt
==24193== 
==24193== 
==24193== HEAP SUMMARY:
==24193==     in use at exit: 0 bytes in 0 blocks
==24193==   total heap usage: 91 allocs, 91 frees, 12,982 bytes allocated
==24193== 
==24193== All heap blocks were freed -- no leaks are possible
==24193== 
==24193== For counts of detected and suppressed errors, rerun with: -v
==24193== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 8 from 6)

Comment 9 errata-xmlrpc 2017-08-22 17:28:39 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:2501