Message ID | cover.1722934012.git.fweimer@redhat.com |
---|---|
Headers |
Return-Path: <libc-alpha-bounces~patchwork=sourceware.org@sourceware.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id C42B7385E45B for <patchwork@sourceware.org>; Tue, 6 Aug 2024 08:48:54 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTP id 8E66A3858C66 for <libc-alpha@sourceware.org>; Tue, 6 Aug 2024 08:48:22 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8E66A3858C66 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 8E66A3858C66 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.129.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1722934104; cv=none; b=krAA2sCLk1nMe4H6luJ5qEnb2zDyNzhLsUjw59+wHwV0FIYBmEluIZEAp5EVXs5dXduMDLorEI+x2ZAMA2rszLoWQYQnSLuuRW/yyJ9Dc3njjyFRVqq4menXNejdCQLu6gHuTW7JAA52eZZJ5IIBGN9KJhCfiC9yjPqLxkByAN4= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1722934104; c=relaxed/simple; bh=/3KpR2xgBm//eXoJ2yVnXHPuuEDLwFGfOgZgXi4YoNI=; h=DKIM-Signature:From:To:Subject:Message-ID:Date:MIME-Version; b=qdhnAQg1fTbCldfemRcXECWhakS/yq4wSt98a8I3x9JZHSPTmgs5yi02EEKg59SFmp7Ol7PnPuVOAi9oNepmZo4bVNdklRLVlFu9yxFuLKkrDVNWPQWVkv0G1PkFcUE9by8G489/mSKl38xsm5wZhLc42MPO5/2EIhKcMilrDl8= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1722934102; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type; bh=PHTx9BVsGmEUp4vXlyTpU51iOcGBzYYAs74dr+A/hqQ=; b=B6NGQfGn42+mN9DjhQKhKth/at6MXFdfkrgM9PE28Suf5xSYv7cT4+3AUPboc+ioShW3Kt vRlRWRlKIurBaL2TlWGpWP03rRPB/GiWtsQpcVwtHpvJ5HqO1KabUocfAXy7T0geMRQz1u kKapmrDGjT5aaRtfYrqzgxnSEHTiGXA= Received: from mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-251-Pf3sa4jqMMmaa7G_z6Fpyg-1; Tue, 06 Aug 2024 04:48:19 -0400 X-MC-Unique: Pf3sa4jqMMmaa7G_z6Fpyg-1 Received: from mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.15]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id F21E01956048 for <libc-alpha@sourceware.org>; Tue, 6 Aug 2024 08:48:18 +0000 (UTC) Received: from oldenburg.str.redhat.com (unknown [10.45.224.40]) by mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id E16C31955D45 for <libc-alpha@sourceware.org>; Tue, 6 Aug 2024 08:48:17 +0000 (UTC) From: Florian Weimer <fweimer@redhat.com> To: libc-alpha@sourceware.org Subject: [PATCH 0/3] Make ld.so self-relocation/main malloc switch more robust Message-ID: <cover.1722934012.git.fweimer@redhat.com> X-From-Line: 61844731147e785796f487d75519012bf50124c2 Mon Sep 17 00:00:00 2001 Date: Tue, 06 Aug 2024 10:48:15 +0200 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.15 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain X-Spam-Status: No, score=-4.8 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Libc-alpha mailing list <libc-alpha.sourceware.org> List-Unsubscribe: <https://sourceware.org/mailman/options/libc-alpha>, <mailto:libc-alpha-request@sourceware.org?subject=unsubscribe> List-Archive: <https://sourceware.org/pipermail/libc-alpha/> List-Post: <mailto:libc-alpha@sourceware.org> List-Help: <mailto:libc-alpha-request@sourceware.org?subject=help> List-Subscribe: <https://sourceware.org/mailman/listinfo/libc-alpha>, <mailto:libc-alpha-request@sourceware.org?subject=subscribe> Errors-To: libc-alpha-bounces~patchwork=sourceware.org@sourceware.org |
Series |
Make ld.so self-relocation/main malloc switch more robust
|
|
Message
Florian Weimer
Aug. 6, 2024, 8:48 a.m. UTC
This was reported as a failure downstream due to not having commit ee1ada1bdb8074de6e1bdc956ab19aef7b6a7872 ("elf: Rework exception handling in the dynamic loader [BZ #25486]"). I think it makes sense to clean this up further and make things more robust. Tested on x86_64-linux-gnu. Thanks, Florian Florian Weimer (3): elf: rtld_multiple_ref is always true elf: Introduce _dl_relocate_object_no_relro elf: Switch to main malloc after final ld.so self-relocation elf/Makefile | 9 +++ elf/dl-reloc.c | 24 +++++--- elf/dl-support.c | 3 +- elf/rtld.c | 102 ++++++++++++++----------------- elf/tst-rtld-no-malloc-audit.c | 1 + elf/tst-rtld-no-malloc-preload.c | 1 + elf/tst-rtld-no-malloc.c | 75 +++++++++++++++++++++++ sysdeps/generic/ldsodefs.h | 7 +++ 8 files changed, 154 insertions(+), 68 deletions(-) create mode 100644 elf/tst-rtld-no-malloc-audit.c create mode 100644 elf/tst-rtld-no-malloc-preload.c create mode 100644 elf/tst-rtld-no-malloc.c base-commit: d7eca2714f0da98894baa15e4c4735297ecd738d