Bug 2058230 - glibc: Fix regression (ldd crash) during dependency sorting in ld.so
Summary: glibc: Fix regression (ldd crash) during dependency sorting in ld.so
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: glibc
Version: 9.0
Hardware: All
OS: All
high
medium
Target Milestone: rc
: 9.0
Assignee: glibc team
QA Contact: Sergey Kolosov
URL:
Whiteboard:
Depends On:
Blocks: 2060778
TreeView+ depends on / blocked
 
Reported: 2022-02-24 14:33 UTC by Florian Weimer
Modified: 2023-07-18 14:29 UTC (History)
9 users (show)

Fixed In Version: glibc-2.34-27.el9_0
Doc Type: No Doc Update
Doc Text:
Clone Of:
: 2060778 (view as bug list)
Environment:
Last Closed: 2022-05-17 15:48:54 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-113674 0 None None None 2022-02-24 14:37:20 UTC
Red Hat Product Errata RHBA-2022:3917 0 None None None 2022-05-17 15:49:12 UTC
Sourceware 28868 0 P2 UNCONFIRMED Dynamic loader DFS algorithm segfaults on missing libraries 2022-02-24 14:33:54 UTC

Description Florian Weimer 2022-02-24 14:33:55 UTC
With LD_TRACE_LOADED_OBJECTS=1, fake objects cause the new (default) dependency sorting algorithm to crash.

Comment 4 Florian Weimer 2022-02-28 10:44:48 UTC
One way to reproduce this:

dnf install java-17-openjdk
ldd /usr/lib/jvm/java-17-openjdk-17*/lib/libnio.so

With the bug present, ld.so crashes with:

Inconsistency detected by ld.so: dl-sort-maps.c: 239: _dl_sort_maps_dfs: Assertion `rpo_head == rpo' failed!

Or fails with exit status 1 (as seen on x86_64).

With the bug fixed, the output contains two “=> not found” lines.

Note that this reproducer is not completely reliable and may stop reproducing the bug due to OpenJDK changes etc. But ld.so is expected to produce some output for valid ELF objects (no crash).

Comment 12 errata-xmlrpc 2022-05-17 15:48:54 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 (new packages: glibc), 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-2022:3917


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