From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 04 04:23:14 2021 Received: (at 50960) by debbugs.gnu.org; 4 Oct 2021 08:23:14 +0000 Received: from localhost ([127.0.0.1]:35583 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mXJFa-0007gq-U9 for submit@debbugs.gnu.org; Mon, 04 Oct 2021 04:23:14 -0400 Received: from eggs.gnu.org ([209.51.188.92]:45922) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mXJFW-0007fy-9i for 50960@debbugs.gnu.org; Mon, 04 Oct 2021 04:23:06 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:44350) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mXJFQ-00028b-P8; Mon, 04 Oct 2021 04:22:56 -0400 Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=60528 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mXJFQ-0003Zi-FT; Mon, 04 Oct 2021 04:22:56 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: "pelzflorian (Florian Pelz)" Subject: Re: bug#50960: [PATCH 00/10] Add 'guix shell' to subsume 'guix environment' References: <20211002102116.27726-1-ludo@gnu.org> <20211002115958.rzupz4afq7elehq4@pelzflorian.localdomain> <87sfxjzgsv.fsf_-_@gnu.org> <20211002150851.7xa2wdb225dbjtpi@pelzflorian.localdomain> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 13 =?utf-8?Q?Vend=C3=A9miaire?= an 230 de la =?utf-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Mon, 04 Oct 2021 10:22:54 +0200 In-Reply-To: <20211002150851.7xa2wdb225dbjtpi@pelzflorian.localdomain> (pelzflorian@pelzflorian.de's message of "Sat, 2 Oct 2021 17:08:51 +0200") Message-ID: <87ee91ryg1.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-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 50960 Cc: 50960@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: -1.0 (-) Hi, "pelzflorian (Florian Pelz)" skribis: > On Sat, Oct 02, 2021 at 03:40:00PM +0200, Ludovic Court=C3=A8s wrote: >> "pelzflorian (Florian Pelz)" skribis: >> > On Sat, Oct 02, 2021 at 12:21:16PM +0200, Ludovic Court=C3=A8s wrote: >> >> 2. =E2=80=98guix shell=E2=80=99, without arguments, loads =E2=80=98gu= ix.scm=E2=80=99 or =E2=80=98manifest.scm=E2=80=99 >> >> from the current directory or one of its ancestors. >> > This however is concerning. Users will not expect guix to execute >> > arbitrary code. Maybe print a suggestion to maybe --file the file >> > instead. >> I think it=E2=80=99s fine as long as, as in the case of =E2=80=98haunt b= uild=E2=80=99 or =E2=80=98make=E2=80=99 >> or =E2=80=98git=E2=80=99, it=E2=80=99s properly documented. Also, =E2= =80=98guix shell=E2=80=99 unconditionally >> writes a message. > > Let=E2=80=99s say I have downloaded undesirable code to a file > /home/florian/Downloads/guix.scm and am hacking on source code in > /home/florian/Downloads/something/ where I run `guix shell`, but > /home/florian/Downloads/something/ does not in fact contain a > guix.scm file. Now I=E2=80=99d have accidentally run the other guix.scm. Sure, but it=E2=80=99s all under your control; it=E2=80=99s not very differ= ent from someone knowingly running =E2=80=9Cguix build -f guix.scm=E2=80=9D on an un= trusted file, is it? > Also `make` is typically used without arguments, but a novice `guix > shell` user might know `guix shell program-a program-b` but is > surprised when running `guix shell` without arguments in an untrusted > directory. We have the advantage that =E2=80=98guix shell=E2=80=99 is a new command, s= o we can document it from the start as behaving this way without arguments. WDYT? Thanks, Ludo=E2=80=99.