From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id 4EAHKGsIW2GrTQAAgWs5BA (envelope-from ) for ; Mon, 04 Oct 2021 15:58:03 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id AL6vI2sIW2HIHQAA1q6Kng (envelope-from ) for ; Mon, 04 Oct 2021 13:58:03 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 5E46B2D035 for ; Mon, 4 Oct 2021 15:58:03 +0200 (CEST) Received: from localhost ([::1]:38450 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mXOTi-0007CV-Ha for larch@yhetil.org; Mon, 04 Oct 2021 09:58:02 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40420) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mXOOs-0007SD-MC for guix-patches@gnu.org; Mon, 04 Oct 2021 09:53:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:52668) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mXOOs-0005bs-Ct for guix-patches@gnu.org; Mon, 04 Oct 2021 09:53:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mXOOs-0003yI-Bg for guix-patches@gnu.org; Mon, 04 Oct 2021 09:53:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50698] [PATCH] WIP patches for recently-known hurd security vulnerabilities Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 04 Oct 2021 13:53:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50698 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch security To: Maxime Devos Cc: 50698@debbugs.gnu.org Received: via spool by 50698-submit@debbugs.gnu.org id=B50698.163335555915212 (code B ref 50698); Mon, 04 Oct 2021 13:53:02 +0000 Received: (at 50698) by debbugs.gnu.org; 4 Oct 2021 13:52:39 +0000 Received: from localhost ([127.0.0.1]:35981 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mXOOU-0003xH-Na for submit@debbugs.gnu.org; Mon, 04 Oct 2021 09:52:39 -0400 Received: from eggs.gnu.org ([209.51.188.92]:35164) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mXOOS-0003x0-Re for 50698@debbugs.gnu.org; Mon, 04 Oct 2021 09:52:37 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:54592) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mXOOM-0005Bt-M5; Mon, 04 Oct 2021 09:52:30 -0400 Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=60548 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mXOOL-0004lR-Kk; Mon, 04 Oct 2021 09:52:30 -0400 From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <727b3d7ec511589ab714874d6648ee4afa458e3c.camel@telenet.be> Date: Mon, 04 Oct 2021 15:52:27 +0200 In-Reply-To: <727b3d7ec511589ab714874d6648ee4afa458e3c.camel@telenet.be> (Maxime Devos's message of "Mon, 20 Sep 2021 12:40:48 +0200") Message-ID: <87pmskq4mc.fsf@gnu.org> 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-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1633355883; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=7MG04xmV1Q4nH5h4wfMDkSSlUSkpvzFxtc/HD7Z4XCs=; b=iLpNZHzvEvWhrBnYHsxyzlPDOWIe0P8XiJnPJNQx0FCE2LlRGSV3iDtnMrGMFtUo00Tlp0 m1EWtaSrlf5jFRGAz0VvtVJa1dZlDsL8tuPWlaywlIzO1hPUe6c6pkdZ3zK8I8h434g3nf AbCAhxbTHq4CYPfoklCIjtZYR8OF4tQkpSmRj0untwrxv+42/2sUn7X5UL8JRoeIMJhbT1 TuEjZM05paAoHI+k28Br6RSDDWJaZsV5SvGHw14/+w0CYa6fwGvnZo9UfURN943xR3/8XO LlmfLs9Qc3O1yDHa8Zap/uQBe+lo+WCl9EW7iWsRKB/LrqvtbOvMBrBURzTtoA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1633355883; a=rsa-sha256; cv=none; b=gwhGdvQ4RYj3Ms4uVybOgOkEgO8k1ty0WuUa+XVOViTdG5OBv5HkMSMijQp+rZB1v+cERA Dcjbt/aPEG3BznwlCrrK3eUMScJOtS060LQwtVtPArX1nbNg81LJdSzz6uQSj4za7ByAAT JfRPBrZCO2nRo0UL8g/MJwcE3mz+N3k8JGf9Z6NKKHbdZyJBYdD4J6NOnVkJMeYmIfxmvh 6klS0+feV88dzgRNPxTzMnQZlPFpuWx0fh63KVrtS4x7AXKUhw2/f7M+C/VvkzoRN1iadp BgfaO2AjrwETpblxaHVQZOBjVlholXwdMvHvtKaatTG80mwA4RS62Ae6VSM9hg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -2.91 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 5E46B2D035 X-Spam-Score: -2.91 X-Migadu-Scanner: scn0.migadu.com X-TUID: Sj3/gbg7oDeI Hi Maxime, Maxime Devos skribis: > I've tried to patch the glibc package for the problems noted at > ;. > > I've found two recent patches (glibc-hurd-proc-reauth.patch and > glibc-hurd-sendmsg-SCM_CREDS.patch) that appeared relevant. I tried > to patch our glibc package with those patches. > > The modified tarball builds fine for --system=3Dx86_64-linux, but not > for --system=3Di586-gnu (tested with ./pre-inst-env guix build hello > --system=3Di586-gnu). Any idea what's happening here? Thanks for looking into it! > From cdf38fbfcba4c87777d7ba2175f08e877dafe86a Mon Sep 17 00:00:00 2001 > From: Maxime Devos > Date: Mon, 13 Sep 2021 11:23:21 +0200 > Subject: [PATCH] WIP gnu: glibc: New security patches. > MIME-Version: 1.0 > Content-Type: text/plain; charset=3DUTF-8 > Content-Transfer-Encoding: 8bit > > The existence of the vulnerabilities was noted at > . > > TODO: check if these are all necessary packages for glibc. > TODO: why does the glibc tarball build for --system=3Dx86_64-linux but not > for --system=3Di586-gnu? > > Build error: > =E2=80=98patching file hurd/hurdinit.c > Hunk #1 FAILED at 177. > 1 out of 1 hunk FAILED -- saving rejects to file hurd/hurdinit.c.rej=E2= =80=99 > > but this file isn't modified by the new patches! > > * gnu/local.mk (dist_patch_DATA): Register new patches. > * gnu/packages/base.scm (glibc)[replacement]: Register replacement. > (glibc/fixed): New variable. > * gnu/packages/patches/glibc-hurd-proc-reauth.patch: New file. > * gnu/packages/patches/glibc-hurd-sendmsg-SCM_CREDS.patch. [...] > --- a/gnu/packages/base.scm > +++ b/gnu/packages/base.scm > @@ -706,6 +706,7 @@ the store.") > (package > (name "glibc") > (version "2.31") > + (replacement glibc/fixed) > (source (origin > (method url-fetch) > (uri (string-append "mirror://gnu/glibc/glibc-" version ".ta= r.xz")) > @@ -966,6 +967,12 @@ with the Linux kernel.") > (license lgpl2.0+) > (home-page "https://www.gnu.org/software/libc/"))) >=20=20 > +(define glibc/fixed > + (package-with-extra-patches > + glibc > + (search-patches "glibc-hurd-sendmsg-SCM_CREDS.patch" > + "glibc-hurd-proc-reauth.patch"))) Instead of a replacement, which makes no sense on GNU/Linux, could you add a conditional phase for (hurd-target?) that applies the patches? (On =E2=80=98core-updates=E2=80=99 (or =E2=80=98-frozen=E2=80=99?) we will = apply patches unconditionally.) Not answering your initial question, but maybe the problem will vanish if you do things this way, who knows. :-) > +++ b/gnu/packages/patches/glibc-hurd-proc-reauth.patch > @@ -0,0 +1,114 @@ > +Index: glibc-2.31/hurd/hurdsig.c Please add a comment explaining what this patch does, what its status is, with a link to upstream discussions. Thank you! Ludo=E2=80=99.