From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id INYuOlF2WGEfKQEAgWs5BA (envelope-from ) for ; Sat, 02 Oct 2021 17:10:09 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id ULKkNVF2WGGaSgAAbx9fmQ (envelope-from ) for ; Sat, 02 Oct 2021 15:10:09 +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 AF8282F616 for ; Sat, 2 Oct 2021 17:10:09 +0200 (CEST) Received: from localhost ([::1]:44018 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mWgeO-0007FK-SJ for larch@yhetil.org; Sat, 02 Oct 2021 11:10:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:53966) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mWgeI-0007BN-P4 for guix-patches@gnu.org; Sat, 02 Oct 2021 11:10:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:48712) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mWgeI-0003sP-HK for guix-patches@gnu.org; Sat, 02 Oct 2021 11:10:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mWgeI-0005p4-CA for guix-patches@gnu.org; Sat, 02 Oct 2021 11:10:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50960] [PATCH 00/10] Add 'guix shell' to subsume 'guix environment' Resent-From: "pelzflorian (Florian Pelz)" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 02 Oct 2021 15:10:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50960 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 50960@debbugs.gnu.org Received: via spool by 50960-submit@debbugs.gnu.org id=B50960.163318734322302 (code B ref 50960); Sat, 02 Oct 2021 15:10:02 +0000 Received: (at 50960) by debbugs.gnu.org; 2 Oct 2021 15:09:03 +0000 Received: from localhost ([127.0.0.1]:60258 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mWgdL-0005ne-6d for submit@debbugs.gnu.org; Sat, 02 Oct 2021 11:09:03 -0400 Received: from pelzflorian.de ([5.45.111.108]:49940 helo=mail.pelzflorian.de) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mWgdJ-0005n8-RB for 50960@debbugs.gnu.org; Sat, 02 Oct 2021 11:09:02 -0400 Received: from pelzflorian.localdomain (unknown [5.45.111.108]) by mail.pelzflorian.de (Postfix) with ESMTPSA id 40C1036069D; Sat, 2 Oct 2021 17:09:00 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=pelzflorian.de; s=mail; t=1633187340; bh=luT0CiCSAeSZww9AS5pp+DAtidQtxbwfutT+yerzEZ0=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=KhaGe7MkIarT70PbJjjW0PgzX8UR9axk/XUvWic0qbVjo0GRbxJ3kHHTJJ998MIgj 6osi0+2Emv7ENZwXvKMTA2pPAlbTF7VX6UY3JpGZG0/IKPoEYPABvOl6aNmVJkkKTD 9TOdAe4mmOpw1wodQIDhLv7pQWHW/evhi7iTtW0c= Date: Sat, 2 Oct 2021 17:08:51 +0200 From: "pelzflorian (Florian Pelz)" Message-ID: <20211002150851.7xa2wdb225dbjtpi@pelzflorian.localdomain> References: <20211002102116.27726-1-ludo@gnu.org> <20211002115958.rzupz4afq7elehq4@pelzflorian.localdomain> <87sfxjzgsv.fsf_-_@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <87sfxjzgsv.fsf_-_@gnu.org> 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=1633187409; 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:dkim-signature; bh=9Q/lOEa9TjRqYdfOgUfqr6+0WqrjUFWrngsKl1qe8Z0=; b=SO2ErevcnMVtu37lLlw7KgrRGXfU6IQIBbjJFwARaUARqBEwnebVKaHTwPKNrfJNSJmVAd CtzIRgUJixIZLL96pcY71b6uU5yuqNRIFVQO9FNDChGLiT8UhQX2HK5iJU1eLAOdWPd9JV dr3g9DJtbS0aanzQ5Gb+kDpX4AQYbw+iRldfQHo6/k5BSzgvTqVoeV1aiGlhPh7zUSx+GE 65Rysr+jVFFcjTjMRaTjjSakEqrQnRXG1kwjnM9rlwh1CB6nwxBXK+Yu3MN7RreSXCBnVI An8AbnibptM0kyBRmamFcykVA0Tsy+SsMMkt7kgoViwYZ7cBe0E2IDZlef5xpg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1633187409; a=rsa-sha256; cv=none; b=TKSERWJ9YN2ZU1+JvbeElk77u5dkXabHlUuRtMvSJ+TQlCj0HGfT9y/Dfu8UHf9JooNPmF PniPf1xedH74WQKfBU1App9+L1gfV0QewMuHRPcBs8NwTyYPX6rBe3jQD16IZC5LZXVQqD rq3VfKSL1aC6AhKrvje5tszcnjk6LZd9EfNoARnUF4U99GBgHiz3gbcfMBVhIOXyFDvsK8 hsUO9Lqu4rrADCJcW+p4AofUAgxjNtCO8aa1e2SkNPwyamUpZ3Mntg2IVfZYxui6nKW1gl qGG6X16m1itk4lGGNZNKFOn/WxmPvNcEOiIQygxn05aVLnyvoZ76Z1RaL6YuhQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=pelzflorian.de header.s=mail header.b=KhaGe7Mk; dmarc=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: -1.40 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=pelzflorian.de header.s=mail header.b=KhaGe7Mk; dmarc=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-Queue-Id: AF8282F616 X-Spam-Score: -1.40 X-Migadu-Scanner: scn0.migadu.com X-TUID: MX0JVn/QTAD7 On Sat, Oct 02, 2021 at 03:40:00PM +0200, Ludovic Courtès wrote: > "pelzflorian (Florian Pelz)" skribis: > > On Sat, Oct 02, 2021 at 12:21:16PM +0200, Ludovic Courtès wrote: > >> 2. ‘guix shell’, without arguments, loads ‘guix.scm’ or ‘manifest.scm’ > >> 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’s fine as long as, as in the case of ‘haunt build’ or ‘make’ > or ‘git’, it’s properly documented. Also, ‘guix shell’ unconditionally > writes a message. Let’s 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’d have accidentally run the other guix.scm. 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. But yes, git hooks are dangerous too. Regards, Florian