GNU bug report logs - #52693
[PATCH] gnu: glibc: Handle failure to find $ORIGIN.

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: guix-patches; Reported by: Ivan Kozlov <kanichos@HIDDEN>; Keywords: patch; dated Tue, 21 Dec 2021 01:27:01 UTC; Maintainer for guix-patches is guix-patches@HIDDEN.

Message received at 52693 <at> debbugs.gnu.org:


Received: (at 52693) by debbugs.gnu.org; 14 Jan 2022 22:40:55 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Jan 14 17:40:55 2022
Received: from localhost ([127.0.0.1]:38510 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1n8VFe-00084H-UU
	for submit <at> debbugs.gnu.org; Fri, 14 Jan 2022 17:40:55 -0500
Received: from mail-qv1-f54.google.com ([209.85.219.54]:41623)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <maxim.cournoyer@HIDDEN>) id 1n8VFc-000840-Hg
 for 52693 <at> debbugs.gnu.org; Fri, 14 Jan 2022 17:40:53 -0500
Received: by mail-qv1-f54.google.com with SMTP id hu2so11473814qvb.8
 for <52693 <at> debbugs.gnu.org>; Fri, 14 Jan 2022 14:40:52 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
 h=from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version:content-transfer-encoding;
 bh=0MObIfq9yUEQYNzIUC1ZCpsNvKIhFI5c5Y77t3RXu80=;
 b=lFLElekHoSIek5SQeoG/jDtpltLzWUakdpprlW5NXuckG10hq4zThvzG/JXY+eiL/W
 ad26zRW+b1/V5YkASYwtvFkIrbb46WSG/K4lcPw7X048SzcXo6EUnVah8EotgbYGVJ49
 ULke9mNxUv424A+jy6rfcYHqcrWw9kys9bhl8O+Vzhofd1nrrQMYUUzSYowpVXcYYLpf
 ekKq4ntF4QxoHH8UQ2KHNZ60bWEuDTtTb9unduIjvvL8YyleZ/aYs2MvDixae+K9Xn2n
 MnDWucx3XA+HPRuOLwAb1YxpyEqLgvzBA+urkl775aDzgH/ESfRGLv4tafj7R6NNJpvt
 sA3w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20210112;
 h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to
 :message-id:user-agent:mime-version:content-transfer-encoding;
 bh=0MObIfq9yUEQYNzIUC1ZCpsNvKIhFI5c5Y77t3RXu80=;
 b=sovIHwzbhA4lZhkTCZMexCYcF7wU2V9M53RQetJQVB01RTDvPB9BmnnaZ3FBO77Eoo
 M/NnDiZB+npooIaD0UeqMImn3RnRYUsiPxmwtbkdatzCs5q+2sDRihAzM/8S0HV1VGzT
 VCXbduaNHiIyifq7BiVstV3oMLaGNa30oiNBK8tTMF2y6jqMbts6UuSmLjruAbwWiMad
 w7aSDrXaK6RYkxjR5qw163kC4gur+TRL0V6KBfUDZt2BzcGulVY8TfqPdyr+oTN5DkxW
 e5g9sK8SGfUZhtoYLot0uA/NA+nmRW7CzkV8Z3YKB9akdSKhuO7VFFRlmrqKTHGWcCHW
 SCzw==
X-Gm-Message-State: AOAM532hEk4M2wqBv4r4/0edgfelwSZbu7ocjd0NK5QYJ46mQUefyHCi
 p4AdD1s5Zhos28tOXZnRebLNOSHbv4U=
X-Google-Smtp-Source: ABdhPJzfiRbnuIt1WnFdQWO/7dc4H6Lm5ojRExBm2JDUAlO6oI9xSWxzh1Jnt7+f9gdNBd/RYyz8RQ==
X-Received: by 2002:a05:6214:300b:: with SMTP id
 ke11mr10250029qvb.8.1642200046726; 
 Fri, 14 Jan 2022 14:40:46 -0800 (PST)
Received: from hurd (dsl-152-155.b2b2c.ca. [66.158.152.155])
 by smtp.gmail.com with ESMTPSA id d10sm555071qtb.63.2022.01.14.14.40.45
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
 Fri, 14 Jan 2022 14:40:46 -0800 (PST)
From: Maxim Cournoyer <maxim.cournoyer@HIDDEN>
To: Ludovic =?utf-8?Q?Court=C3=A8s?= <ludo@HIDDEN>
Subject: Re: bug#52693: [PATCH] gnu: glibc: Handle failure to find $ORIGIN.
References: <12919001640049950@HIDDEN>
 <87a6fy684t.fsf@HIDDEN>
Date: Fri, 14 Jan 2022 17:40:44 -0500
In-Reply-To: <87a6fy684t.fsf@HIDDEN> ("Ludovic =?utf-8?Q?Court=C3=A8s=22'?=
 =?utf-8?Q?s?= message of "Fri, 14 Jan 2022 09:20:34 +0100")
Message-ID: <87wnj29c0j.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 52693
Cc: 52693 <at> debbugs.gnu.org, Ivan Kozlov <kanichos@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Hi,

Ludovic Court=C3=A8s <ludo@HIDDEN> writes:

> Hello,
>
> Ivan Kozlov <kanichos@HIDDEN> skribis:
>
>> Fixes <https://issues.guix.gnu.org/52671>.
>>
>> * gnu/packages/patches/glibc-dl-cache.patch: Check pointer returned
>> by '_dl_get_origin' for failure indication.

Is this a world rebuilding change?  If so, I'm afraid it'll have to wait
until the next rebuild cycle comes as we're already far into building
the version-1.4.0 branch.

Thanks,

Maxim




Information forwarded to guix-patches@HIDDEN:
bug#52693; Package guix-patches. Full text available.

Message received at 52693 <at> debbugs.gnu.org:


Received: (at 52693) by debbugs.gnu.org; 14 Jan 2022 08:20:45 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Jan 14 03:20:45 2022
Received: from localhost ([127.0.0.1]:35447 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1n8HpF-0006is-BR
	for submit <at> debbugs.gnu.org; Fri, 14 Jan 2022 03:20:45 -0500
Received: from hera.aquilenet.fr ([185.233.100.1]:53276)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <ludo@HIDDEN>) id 1n8HpD-0006ia-Ts
 for 52693 <at> debbugs.gnu.org; Fri, 14 Jan 2022 03:20:44 -0500
Received: from localhost (localhost [127.0.0.1])
 by hera.aquilenet.fr (Postfix) with ESMTP id 306C53D2;
 Fri, 14 Jan 2022 09:20:37 +0100 (CET)
X-Virus-Scanned: Debian amavisd-new at aquilenet.fr
Received: from hera.aquilenet.fr ([127.0.0.1])
 by localhost (hera.aquilenet.fr [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id 97--CBERL-Wr; Fri, 14 Jan 2022 09:20:36 +0100 (CET)
Received: from ribbon (91-160-117-201.subs.proxad.net [91.160.117.201])
 by hera.aquilenet.fr (Postfix) with ESMTPSA id 8FFC8242;
 Fri, 14 Jan 2022 09:20:35 +0100 (CET)
From: =?utf-8?Q?Ludovic_Court=C3=A8s?= <ludo@HIDDEN>
To: Ivan Kozlov <kanichos@HIDDEN>
Subject: Re: bug#52693: [PATCH] gnu: glibc: Handle failure to find $ORIGIN.
References: <12919001640049950@HIDDEN>
Date: Fri, 14 Jan 2022 09:20:34 +0100
In-Reply-To: <12919001640049950@HIDDEN> (Ivan
 Kozlov's message of "Tue, 21 Dec 2021 04:25:50 +0300")
Message-ID: <87a6fy684t.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spamd-Bar: /
Authentication-Results: hera.aquilenet.fr;
	none
X-Rspamd-Server: hera
X-Rspamd-Queue-Id: 306C53D2
X-Spamd-Result: default: False [0.90 / 15.00]; ARC_NA(0.00)[];
 RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[];
 RCPT_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_ALL(0.00)[];
 FREEMAIL_ENVRCPT(0.00)[gmail.com,yandex.ru];
 TAGGED_RCPT(0.00)[]; MIME_GOOD(-0.10)[text/plain];
 SUBJECT_HAS_CURRENCY(1.00)[]; TO_DN_SOME(0.00)[];
 FREEMAIL_TO(0.00)[yandex.ru]; FROM_EQ_ENVFROM(0.00)[];
 MIME_TRACE(0.00)[0:+]; RCVD_COUNT_TWO(0.00)[2];
 RCVD_TLS_ALL(0.00)[]; MID_RHS_MATCH_FROM(0.00)[];
 FREEMAIL_CC(0.00)[debbugs.gnu.org,gmail.com]
X-Spam-Score: 1.0 (+)
X-Debbugs-Envelope-To: 52693
Cc: 52693 <at> debbugs.gnu.org, Maxim Cournoyer <maxim.cournoyer@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.0 (/)

Hello,

Ivan Kozlov <kanichos@HIDDEN> skribis:

> Fixes <https://issues.guix.gnu.org/52671>.
>
> * gnu/packages/patches/glibc-dl-cache.patch: Check pointer returned by '_=
dl_get_origin' for failure indication.

Perfect, thank you Ivan.

Maxim, should we include it in =E2=80=98version-1.4.0=E2=80=99?

I=E2=80=99m fine either way (it=E2=80=99s a much welcome fix but it=E2=80=
=99s not critical IMO).

Ludo=E2=80=99.




Information forwarded to guix-patches@HIDDEN:
bug#52693; Package guix-patches. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 21 Dec 2021 01:26:10 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Dec 20 20:26:10 2021
Received: from localhost ([127.0.0.1]:51824 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mzTuo-0004pY-J3
	for submit <at> debbugs.gnu.org; Mon, 20 Dec 2021 20:26:10 -0500
Received: from lists.gnu.org ([209.51.188.17]:36978)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <kanichos@HIDDEN>) id 1mzTuk-0004pO-Nb
 for submit <at> debbugs.gnu.org; Mon, 20 Dec 2021 20:26:06 -0500
Received: from eggs.gnu.org ([209.51.188.92]:41486)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <kanichos@HIDDEN>)
 id 1mzTuk-0006oV-5q
 for guix-patches@HIDDEN; Mon, 20 Dec 2021 20:26:02 -0500
Received: from forward401j.mail.yandex.net ([5.45.198.233]:52462)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <kanichos@HIDDEN>)
 id 1mzTuf-0005ls-VB
 for guix-patches@HIDDEN; Mon, 20 Dec 2021 20:26:01 -0500
Received: from myt6-06c5907de372.qloud-c.yandex.net
 (myt6-06c5907de372.qloud-c.yandex.net
 [IPv6:2a02:6b8:c12:42ad:0:640:6c5:907d])
 by forward401j.mail.yandex.net (Yandex) with ESMTP id 0FE4F1ACDD71
 for <guix-patches@HIDDEN>; Tue, 21 Dec 2021 04:25:51 +0300 (MSK)
Received: from 2a02:6b8:c12:2487:0:640:27f5:8919
 (2a02:6b8:c12:2487:0:640:27f5:8919 [2a02:6b8:c12:2487:0:640:27f5:8919])
 by myt6-06c5907de372.qloud-c.yandex.net (mxback/Yandex) with HTTP id
 nPVAIG1euOs1-PoeOn0KN; Tue, 21 Dec 2021 04:25:50 +0300
X-Yandex-Fwd: 1
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail;
 t=1640049950; bh=vNedbYRM0BmxtLZTQrsPEBRvufpFKdZhYPrirTd6UuM=;
 h=Message-Id:Date:Subject:To:From;
 b=LUFCZhvGFwrNL9gU5FO4bFqrf6t8jifMC1mO95ywGrEDCKtvFbj+hVBhVbX7dAuxq
 +9XL6DTxhKH8I7n3VjrqZRIr99lYmEFzoWsNaoK2ia6ZTnR+s+js3HnAoukf18mtT2
 6zW4Nq4mHadNn9gKxRKfkkTiz4GgePAs+QKzefaA=
Authentication-Results: myt6-06c5907de372.qloud-c.yandex.net;
 dkim=pass header.i=@yandex.ru
Received: by myt6-27f58919b1c4.qloud-c.yandex.net with HTTP;
 Tue, 21 Dec 2021 04:25:50 +0300
From: Ivan Kozlov <kanichos@HIDDEN>
To: guix-patches@HIDDEN
Subject: [PATCH] gnu: glibc: Handle failure to find $ORIGIN.
MIME-Version: 1.0
X-Mailer: Yamail [ http://yandex.ru ] 5.0
Date: Tue, 21 Dec 2021 04:25:50 +0300
Message-Id: <12919001640049950@HIDDEN>
Content-Transfer-Encoding: 8bit
Content-Type: text/plain; charset=utf-8
Received-SPF: pass client-ip=5.45.198.233; envelope-from=kanichos@HIDDEN;
 helo=forward401j.mail.yandex.net
X-Spam_score_int: -20
X-Spam_score: -2.1
X-Spam_bar: --
X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001,
 SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.3 (--)

Fixes <https://issues.guix.gnu.org/52671>.

* gnu/packages/patches/glibc-dl-cache.patch: Check pointer returned by '_dl_get_origin' for failure indication.
---
 gnu/packages/patches/glibc-dl-cache.patch | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/gnu/packages/patches/glibc-dl-cache.patch b/gnu/packages/patches/glibc-dl-cache.patch
index 68c3a94846..1535e8e9c9 100644
--- a/gnu/packages/patches/glibc-dl-cache.patch
+++ b/gnu/packages/patches/glibc-dl-cache.patch
@@ -3,10 +3,10 @@ from /etc/ld.so.cache.  Also arrange so that this cache takes
 precedence over RUNPATH.

 diff --git a/elf/dl-cache.c b/elf/dl-cache.c
-index 93d185e788..e0760a1f40 100644
+index 93d185e788..801452692d 100644
 --- a/elf/dl-cache.c
 +++ b/elf/dl-cache.c
-@@ -171,6 +171,51 @@ _dl_cache_libcmp (const char *p1, const char *p2)
+@@ -171,6 +171,52 @@ _dl_cache_libcmp (const char *p1, const char *p2)
    return *p1 - *p2;
  }

@@ -27,7 +27,8 @@ index 93d185e788..e0760a1f40 100644
 +      const char *origin = _dl_get_origin ();
 +
 +      /* Check whether ORIGIN is something like "/gnu/store/…-foo/bin".  */
-+      if (strncmp (store, origin, strlen (store)) == 0
++      if (origin != (char *)-1 /* _dl_get_origin reported failure */
++        && strncmp (store, origin, strlen (store)) == 0
 +        && origin[sizeof store - 1] == '/')
 +      {
 +        char *store_item_end = strchr (origin + sizeof store, '/');
@@ -58,7 +59,7 @@ index 93d185e788..e0760a1f40 100644

  /* Look up NAME in ld.so.cache and return the file name stored there, or null
     if none is found.  The cache is loaded if it was not already.  If loading
-@@ -190,12 +235,15 @@ _dl_load_cache_lookup (const char *name)
+@@ -190,12 +236,15 @@ _dl_load_cache_lookup (const char *name)

    /* Print a message if the loading of libs is traced.  */
    if (__glibc_unlikely (GLRO(dl_debug_mask) & DL_DEBUG_LIBS))

base-commit: 88b4dcdabe512992ae79a50fc333e4e463d91634
--
2.28.0




Acknowledgement sent to Ivan Kozlov <kanichos@HIDDEN>:
New bug report received and forwarded. Copy sent to guix-patches@HIDDEN. Full text available.
Report forwarded to guix-patches@HIDDEN:
bug#52693; Package guix-patches. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Fri, 14 Jan 2022 22:45:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.