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 ms11 with LMTPS id WIxrLRsh7V4ycgAA0tVLHw (envelope-from ) for ; Fri, 19 Jun 2020 20:33:31 +0000 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 cJ1BKRsh7V6zQgAA1q6Kng (envelope-from ) for ; Fri, 19 Jun 2020 20:33:31 +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 46DEC9400C1 for ; Fri, 19 Jun 2020 20:33:31 +0000 (UTC) Received: from localhost ([::1]:59884 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jmNha-0000pr-4r for larch@yhetil.org; Fri, 19 Jun 2020 16:33:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50806) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jmNhP-0000lC-B4 for guix-devel@gnu.org; Fri, 19 Jun 2020 16:33:19 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:55385) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jmNhO-0005Qx-U5; Fri, 19 Jun 2020 16:33:18 -0400 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=39262 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1jmNhO-00067k-CF; Fri, 19 Jun 2020 16:33:18 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Christopher Baines Subject: Re: K of N trust in substitutes (related to reproducible builds) References: <87lfkq8ugk.fsf@cbaines.net> <87o8pjwdwx.fsf@gnu.org> <874krabzl5.fsf@cbaines.net> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 2 Messidor an 228 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: Fri, 19 Jun 2020 22:33:17 +0200 In-Reply-To: <874krabzl5.fsf@cbaines.net> (Christopher Baines's message of "Tue, 16 Jun 2020 20:05:58 +0100") Message-ID: <87a70yg5iq.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: guix-devel@gnu.org Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Spam-Score: -1.01 X-TUID: zGyMoez4t5Eq Hi, Christopher Baines skribis: > Ludovic Court=C3=A8s writes: > >>> 3: http://theworld.com/~cme/spki.txt >>> >>> Using the above ACL, you'd trust a substitute for a path with a specific >>> hash if you can find 2 narinfos for that path and hash if they're signed >>> with keys in that entry. Multiple entries would still be supported, and >>> you wouldn't need to specify the k-of-n bit if you don't want to. >>> >>> I'm not quite sure how expressive this is, or if there are some policies >>> that would be good to support that either can't be expressed, or can't >>> be expressed easily. There's probably other approaches, and how to >>> support trusting substitutes is an important part to consider. >> >> I would be tempted to not bake it into /etc/guix/acl. You would still >> authorize all the servers, but instead of choosing a policy that accepts >> anything signed by one of them, as is currently the case, you would >> choose a policy that only accepts something signed by two of them. >> >> The policy would be implemented in (guix scripts substitute). I haven= =E2=80=99t >> put much thought into it but it could be something akin to >> =E2=80=98lookup-narinfos/diverse=E2=80=99, roughly. >> >> Thoughts? > > I think that could work, do you have any suggestions on how that "two" > would be configured? I guess it could be a boolean on/off, but it would > be probably more extensible to just allow providing a minimum number of > substitiute servers to agree. There should be a procedure that takes a list of narinfos signed with an authorized key and returns a Boolean. Then there can be a higher-order procedure returning a predicate, like: (make-ratio-predicate k n) The user-chosen predicate could live in /etc/guix/substitute-policy.scm or similar. Thanks, Ludo=E2=80=99.