Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1625051 - CVE-2018-16402 elfutils: Double-free due to double decompression of sections in crafted ELF causes crash [fedora-all]
Summary: CVE-2018-16402 elfutils: Double-free due to double decompression of sections ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: elfutils
Version: 28
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ---
Assignee: Mark Wielaard
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-09-04 04:27 UTC by Sam Fowler
Modified: 2018-10-02 16:01 UTC (History)
6 users (show)

Fixed In Version: elfutils-0.174-1.fc29 elfutils-0.174-1.fc28
Doc Type: Release Note
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-09-30 23:25:00 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Sam Fowler 2018-09-04 04:27:25 UTC
This is an automatically created tracking bug!  It was created to ensure
that one or more security vulnerabilities are fixed in affected versions
of fedora-all.

For comments that are specific to the vulnerability please use bugs filed
against the "Security Response" product referenced in the "Blocks" field.

For more information see:
http://fedoraproject.org/wiki/Security/TrackingBugs

When submitting as an update, use the fedpkg template provided in the next
comment(s).  This will include the bug IDs of this tracking bug as well as
the relevant top-level CVE bugs.

Please also mention the CVE IDs being fixed in the RPM changelog and the
fedpkg commit message.

NOTE: this issue affects multiple supported versions of Fedora. While only
one tracking bug has been filed, please correct all affected versions at
the same time.  If you need to fix the versions independent of each other,
you may clone this bug as appropriate.

Comment 1 Sam Fowler 2018-09-04 04:27:30 UTC
Use the following template to for the 'fedpkg update' request to submit an
update for this issue as it contains the top-level parent bug(s) as well as
this tracking bug.  This will ensure that all associated bugs get updated
when new packages are pushed to stable.

=====

# bugfix, security, enhancement, newpackage (required)
type=security

# testing, stable
request=testing

# Bug numbers: 1234,9876
bugs=1625050,1625051

# Description of your update
notes=Security fix for [PUT CVEs HERE]

# Enable request automation based on the stable/unstable karma thresholds
autokarma=True
stable_karma=3
unstable_karma=-3

# Automatically close bugs when this marked as stable
close_bugs=True

# Suggest that users restart after update
suggest_reboot=False

======

Additionally, you may opt to use the bodhi web interface to submit updates:

https://bodhi.fedoraproject.org/updates/new

Comment 2 Sam Fowler 2018-09-04 04:30:45 UTC
Reproduces on F28 with elfutils-0.173-1.fc28.x86_64:

# eu-nm CVE-2018-16402 2>&1 | ./asan_symbolizer.py 
eu-nm: CVE-2018-16402: entry size in section 1 `(null)' is not what we expect
=================================================================
==44==ERROR: AddressSanitizer: attempting double-free on 0x604000000390 in thread T0:
    #0 0x7f8fab1f4880 in __interceptor_free (/lib64/libasan.so.5+0xee880)
    #1 0x7f8faabdf884 in elf_end (/lib64/libelf.so.1+0xd884)
    #2 0x7f8faae81dc5 in free_file dwfl_module.c:57
    #3 0x7f8faae821f2 in __libdwfl_module_free dwfl_module.c:113
    #4 0x7f8faae8195b in dwfl_end (/lib64/libdw.so.1+0x6c95b)
    #0 0x5592a1cb900c in ?? /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:1495
    #1 0x5592a1cbb055 in ?? /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:1579
    #2 0x5592a1cbbee2 in ?? /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:375
    #3 0x5592a1cb5538 in ?? /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:250
    #9 0x7f8faa08824a in __libc_start_main (/lib64/libc.so.6+0x2324a)
    #4 0x5592a1cb57f9 in ?? ??:0

0x604000000390 is located 0 bytes inside of 36-byte region [0x604000000390,0x6040000003b4)
freed by thread T0 here:
    #0 0x7f8fab1f4880 in __interceptor_free (/lib64/libasan.so.5+0xee880)
    #1 0x7f8faac07f97 in __libelf_reset_rawdata /usr/src/debug/elfutils-0.173-1.fc28.x86_64/libelf/elf_compress.c:325
    #2 0x7f8faac08455 in elf_compress (/lib64/libelf.so.1+0x36455)
    #3 0x7f8faae86d33 in relocate_section relocate.c:507
    #4 0x7f8faae87c0a in __libdwfl_relocate relocate.c:752
    #5 0x7f8faae96309 in load_dw dwfl_module_getdwarf.c:1335
    #6 0x7f8faae969a7 in find_dw dwfl_module_getdwarf.c:1390
    #5 0x5592a1cb5e3f in getdbg_dwflmod /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:1191
    #8 0x7f8faae8d254 in dwfl_getmodules (/lib64/libdw.so.1+0x78254)
    #6 0x5592a1cb9a1d in show_symbols /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:1277
    #7 0x5592a1cbb055 in handle_elf /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:1579
    #8 0x5592a1cbbee2 in process_file /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:375
    #9 0x5592a1cb5538 in main /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:250
    #13 0x7f8faa08824a in __libc_start_main (/lib64/libc.so.6+0x2324a)

previously allocated by thread T0 here:
    #0 0x7f8fab1f4c48 in malloc (/lib64/libasan.so.5+0xeec48)
    #1 0x7f8faac075fa in __libelf_decompress /usr/src/debug/elfutils-0.173-1.fc28.x86_64/libelf/elf_compress.c:223
    #2 0x7f8faac09288 in elf_compress_gnu (/lib64/libelf.so.1+0x37288)
    #3 0x7f8faae86dab in relocate_section relocate.c:504
    #4 0x7f8faae87c0a in __libdwfl_relocate relocate.c:752
    #5 0x7f8faae96309 in load_dw dwfl_module_getdwarf.c:1335
    #6 0x7f8faae969a7 in find_dw dwfl_module_getdwarf.c:1390
    #10 0x5592a1cb5e3f in getdbg_dwflmod /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:1191
    #8 0x7f8faae8d254 in dwfl_getmodules (/lib64/libdw.so.1+0x78254)
    #11 0x5592a1cb9a1d in show_symbols /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:1277
    #12 0x5592a1cbb055 in handle_elf /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:1579
    #13 0x5592a1cbbee2 in process_file /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:375
    #14 0x5592a1cb5538 in main /usr/src/debug/elfutils-0.173-1.fc28.x86_64/src/nm.c:250
    #13 0x7f8faa08824a in __libc_start_main (/lib64/libc.so.6+0x2324a)

SUMMARY: AddressSanitizer: double-free (/lib64/libasan.so.5+0xee880) in __interceptor_free
==44==ABORTING

Comment 3 Fedora Update System 2018-09-14 13:23:17 UTC
elfutils-0.174-1.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2018-32c8599fe1

Comment 4 Fedora Update System 2018-09-14 20:01:21 UTC
elfutils-0.174-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-32c8599fe1

Comment 5 Fedora Update System 2018-09-29 09:18:06 UTC
elfutils-0.174-1.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-1eec1f0d17

Comment 6 Fedora Update System 2018-09-30 03:03:48 UTC
elfutils-0.174-1.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-1eec1f0d17

Comment 7 Fedora Update System 2018-09-30 23:25:00 UTC
elfutils-0.174-1.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2018-10-02 16:01:54 UTC
elfutils-0.174-1.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.


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