From unknown Sat Jun 14 03:57:35 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#63972 <63972@debbugs.gnu.org> To: bug#63972 <63972@debbugs.gnu.org> Subject: Status: specifying a substitute server without adding its PGP key silently ignores it Reply-To: bug#63972 <63972@debbugs.gnu.org> Date: Sat, 14 Jun 2025 10:57:35 +0000 retitle 63972 specifying a substitute server without adding its PGP key sil= ently ignores it reassign 63972 guix submitter 63972 Attila Lendvai severity 63972 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 09 09:56:34 2023 Received: (at submit) by debbugs.gnu.org; 9 Jun 2023 13:56:34 +0000 Received: from localhost ([127.0.0.1]:59953 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q7cbS-0002pO-3m for submit@debbugs.gnu.org; Fri, 09 Jun 2023 09:56:34 -0400 Received: from lists.gnu.org ([209.51.188.17]:35400) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q7cbP-0002pH-DW for submit@debbugs.gnu.org; Fri, 09 Jun 2023 09:56:32 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q7cbP-000749-6e for bug-guix@gnu.org; Fri, 09 Jun 2023 09:56:31 -0400 Received: from mail-4018.proton.ch ([185.70.40.18]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q7cbJ-00066O-S6 for bug-guix@gnu.org; Fri, 09 Jun 2023 09:56:30 -0400 Date: Fri, 09 Jun 2023 13:55:59 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lendvai.name; s=protonmail3; t=1686318981; x=1686578181; bh=L1OEDjpjaRE4XZDo9g3IOrIJ/GNWHvQi0x5RUWzbQoM=; h=Date:To:From:Subject:Message-ID:Feedback-ID:From:To:Cc:Date: Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector; b=mIE/0VUrzFERMN3nGZdiRk+fKCPbgVZXRm0fjkmNvuFdiBJw0v+zPKOEQDpw9eqbN 7MjtrbEV3DDZLBsUsoxtdvBzgIDurphxXXUiYW3Suto5IE/m9Hm50CVrgSIV4Ua0xs urL6ANP/w6bt7eTuUzOqDXv5qm5Sip994lcRFMJ8ntY13pW9Jfd+aGCIU2Dz8z75pz MTKfLNl6HKjmBIcJXY9bRYu2ZJ48ft7zQpaqfdtjCXAhiNgKIY+L2+wjAaQg5Yxt4o U+63ONlmO2GjOSv2S/LaJGTx8kJFMP0mrrATzZ8ywlR7DUUjMPbjTcSXcL0RivNe5j hoBp2DuYdDltQ== To: "bug-guix@gnu.org" From: Attila Lendvai Subject: specifying a substitute server without adding its PGP key silently ignores it Message-ID: <8Hk2ICrGGiH17DRgfVoPUV-zG47yBPXmAUXfHhSHyz7ditGn3Mt0ZM94NyNkwC8W1JsOJGExU6JesEvK9lq6bzjsx7OWu4UrB_TJBmvdlQo=@lendvai.name> Feedback-ID: 28384833:user:proton MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=185.70.40.18; envelope-from=attila@lendvai.name; helo=mail-4018.proton.ch 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, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) i've installed a new guix, and at the first `guix system reconfigure` i spe= cified a substitute server using --substitute-urls for That Other Channel. = i had to do this, because the config.scm that contains the substitute speci= fication is yet to be applied. it didn't work. it prints everything as usual, including the 100% message f= or that substitute server, but it starts to build packages locally for whic= h substitutes are available. i haven't noticed any indication that there's = a problem with any of the substitute servers. once i've downloaded the .pub and i finally did the right incantation (sudo= guix archive --authorize < signing-key.pub), then it started to download t= he substitutes as i expected. i would much prefer a behavior where a "cryptyc" exception and backtrace is= printed by a toplevel error handler. it has cost me about an hour of my li= fe. i'd suggest the following general strategy for the entire codebase in gener= al: throw exceptions, and let them fly all the way up to the toplevel error han= dler that should print it with a backtrace. this should be the baseline, an= d only then start adding very specific exception handlers to print friendly= and localizable error messages for various situations, and only ever swall= ow exceptions when it's really justified. e.g. a file-not-found error in an= ensure-file-deleted function. --=20 =E2=80=A2 attila lendvai =E2=80=A2 PGP: 963F 5D5F 45C7 DFCD 0A39 -- =E2=80=9CCivilization is in a race between education and catastrophe. Let u= s learn the truth and spread it as far and wide as our circumstances allow.= For the truth is the greatest weapon we have.=E2=80=9D =09=E2=80=94 H.G. Wells (1866=E2=80=931946) From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 09 10:20:12 2023 Received: (at 63972) by debbugs.gnu.org; 9 Jun 2023 14:20:13 +0000 Received: from localhost ([127.0.0.1]:59979 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q7cyK-0003V9-H7 for submit@debbugs.gnu.org; Fri, 09 Jun 2023 10:20:12 -0400 Received: from eggs.gnu.org ([209.51.188.92]:43462) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q7cyI-0003Ut-3Z for 63972@debbugs.gnu.org; Fri, 09 Jun 2023 10:20:11 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q7cyC-0002Jo-7y; Fri, 09 Jun 2023 10:20:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:In-Reply-To:Date:References:Subject:To: From; bh=be3o/c2TTUdKPfVmBCZ5FhNCw47nPrnladLErBqzBSY=; b=b6ZUD+ry32MCrzVHli1m NliCh6DpEpSUoLDWAK1SSRTsp+bW6M5dWLRBcn2OQHMXKQJ1XN2qU8DJ+kviTZ5AsCCQQ85UXeZS5 hU2tBwtNxqv51uBnmHPmpV7FRIG6HM7biDribeFjX0dTOStun9qW4EtBFoL7YCgB61CS8hvG9OHB5 CexKFxhJoHcsGbjwzWdMk4gZ/4IcuJp1EurhwDzCJSIMTNlDeiQy+7RQC9v1hFlCFsC+//Agv/CjN ndbIsYJn3XF8M8ecVBug4aTKaKi0hkVx4KGSBEkMasRfEmf7naJ/eTxXgMRtag/z2h7S7FMME1WQD ZoL/VwIG7nbIxg==; Received: from [193.50.110.239] (helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q7cyB-0006im-RO; Fri, 09 Jun 2023 10:20:04 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Attila Lendvai Subject: Re: bug#63972: specifying a substitute server without adding its PGP key silently ignores it References: <8Hk2ICrGGiH17DRgfVoPUV-zG47yBPXmAUXfHhSHyz7ditGn3Mt0ZM94NyNkwC8W1JsOJGExU6JesEvK9lq6bzjsx7OWu4UrB_TJBmvdlQo=@lendvai.name> Date: Fri, 09 Jun 2023 16:20:00 +0200 In-Reply-To: <8Hk2ICrGGiH17DRgfVoPUV-zG47yBPXmAUXfHhSHyz7ditGn3Mt0ZM94NyNkwC8W1JsOJGExU6JesEvK9lq6bzjsx7OWu4UrB_TJBmvdlQo=@lendvai.name> (Attila Lendvai's message of "Fri, 09 Jun 2023 13:55:59 +0000") Message-ID: <873530wwdr.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 63972 Cc: 63972@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hi, Attila Lendvai skribis: > i've installed a new guix, and at the first `guix system reconfigure` i s= pecified a substitute server using --substitute-urls for That Other Channel= . i had to do this, because the config.scm that contains the substitute spe= cification is yet to be applied. > > it didn't work. it prints everything as usual, including the 100% message= for that substitute server, but it starts to build packages locally for wh= ich substitutes are available. i haven't noticed any indication that there'= s a problem with any of the substitute servers. > > once i've downloaded the .pub and i finally did the right incantation (su= do guix archive --authorize < signing-key.pub), then it started to download= the substitutes as i expected. > > i would much prefer a behavior where a "cryptyc" exception and backtrace = is printed by a toplevel error handler. it has cost me about an hour of my = life. I agree we should print a message when stumbling upon unauthorized substitutes (it=E2=80=99s not OpenPGP, BTW). Note that it=E2=80=99s not completely trivial: you might download substitut= es not signed by one of the keys in the ACL if they happen to match substitutes that *are* signed by one of the authorized keys. Also, when discovery is enabled, it=E2=80=99s preferable to silently ignore neighboring servers that the user did not explicitly specify via =E2=80=98--substitute-urls=E2=80=99. Ludo=E2=80=99.