Received: by 2002:a89:288:0:b0:1f7:eeee:6653 with SMTP id j8csp159654lqh; Mon, 6 May 2024 14:53:57 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUiGfc8X9JzQhXZTxsOskHjbQErbPZIqhFqiCeV0Bh/v7jRAewKy+3k9/En9X7XD7Fc6mD0ITgz5M9BLkbn1TYwq4hROHOwGmaoXS7qDA== X-Google-Smtp-Source: AGHT+IElccPX3chRxXZ7hMjFkBOsucgqMSPQK43x2/yeHOLO9nA5jb01fL5rpi+pQPD5688fgIZg X-Received: by 2002:a05:6214:27e9:b0:6a0:c95b:a8c4 with SMTP id jt9-20020a05621427e900b006a0c95ba8c4mr13587793qvb.23.1715032436798; Mon, 06 May 2024 14:53:56 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715032436; cv=pass; d=google.com; s=arc-20160816; b=gnKkjgkdjza8hbIv+NMLruIwo7LNI7qcpnkv1NhzGe7C3cARvYn0+rSoiaxosmivee 2aiaD0W22piolY3QlzX7sTkZZfRMc8D7M7TviXiWKFpfccYxdD18zhAfJYnrvABbAniw 73VatmQBS3Y/8ogFVeSnJ16BBet3qig944cY31RIiTSnoSzxyPEelaYEs7s2gIz0kEFK kWUkKXyJnSarV2aFecxKgcsiqF7hzRg5zDKJNp+gMkM/URhxJL9QvmgkirXJhCLweE1C z64bClzVx9P91qbumDaB1przvzOWoDnnmziO+r0b8LRhpb1CgVBL26ZwCFpTgQ2UI563 T33Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=EeUVpQq/22mOYcKReCK3JqvU1k/TRLUaHjaQZvRF2NE=; fh=nX67w0w6n2j1IJKWsSv2UkZYUvr7+/yXfnh1NrgsOrs=; b=I1GE/dFZzQtVXgL48Scc7cpGd01tccq3SojrX+h/i3KWDZFbSGJXAiDdOaXzY2vM8M QkR9e/m8aE2WjflfI0y3UWUvvTc7byTRSUQPPVbUAylJaVhr+Soaa+283/84UQKpU0qF pbW4iNAaucKv1r0s0zZorhnOeFreJ8XPGq11gSmhrG2ROFoP2PGNlghI9f96e1aOtgQm tXFpFkD+PqrbjTVXDIWvdGwOvrVVp3lqz/SHLMnqt9U6Ztm17z786RhbCdGWSed4v5k1 pLRZoPikUt0Kszy5Fl5NHKzPjiGr+KzQUoTfgGDa6k01HbnOZepwiwvOdYLOdLcBT5QU vZQA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amacapital-net.20230601.gappssmtp.com header.s=20230601 header.b=b9etqhUY; arc=pass (i=1 spf=pass spfdomain=amacapital.net dkim=pass dkdomain=amacapital-net.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-170452-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-170452-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id gv5-20020a056214262500b006a0af94536esi10228833qvb.398.2024.05.06.14.53.56 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 May 2024 14:53:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-170452-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@amacapital-net.20230601.gappssmtp.com header.s=20230601 header.b=b9etqhUY; arc=pass (i=1 spf=pass spfdomain=amacapital.net dkim=pass dkdomain=amacapital-net.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-170452-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-170452-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 735821C21C8F for ; Mon, 6 May 2024 21:53:56 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2F0D215CD76; Mon, 6 May 2024 21:53:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=amacapital-net.20230601.gappssmtp.com header.i=@amacapital-net.20230601.gappssmtp.com header.b="b9etqhUY" Received: from mail-vk1-f177.google.com (mail-vk1-f177.google.com [209.85.221.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A6A6815B992 for ; Mon, 6 May 2024 21:53:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.177 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715032417; cv=none; b=ZGKOPZ0gwPPUhbatJj2BJskMaEUy/tM2HZEjaFHuBFQYNh7ik7qOiB7GVeZsJd2+ITIY5dq07E7iNCy6egTsUC3iuJCf3rlBDZi7qaxGWHdSi2X9z1d7DVZxb5JaCzLgmdEicOUHdO8YkMvYxjc7RIl4CrAIoH9vvKp01wFGuno= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715032417; c=relaxed/simple; bh=6z2N8CtrbVaimdDtZ0PAq6tAC1qn5J+ZvkytA5tacSE=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=sGqFgS33UWjcC26reFrw1NJoh+npZgtEZUA7zEH2OpnUjbsmCs5GKGBovrmOPzym6rC0y+t613UdtbC5Fj1bNR4OAZpYRPKsyX96aMUVbf+SsFt+ND+nc37lX/MGU02YA7zOEFEQNDDRkhaYWRpgUhALIru9zjdONyrzewfw22c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=amacapital.net; spf=pass smtp.mailfrom=amacapital.net; dkim=pass (2048-bit key) header.d=amacapital-net.20230601.gappssmtp.com header.i=@amacapital-net.20230601.gappssmtp.com header.b=b9etqhUY; arc=none smtp.client-ip=209.85.221.177 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=amacapital.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=amacapital.net Received: by mail-vk1-f177.google.com with SMTP id 71dfb90a1353d-4df2fcafc19so646582e0c.0 for ; Mon, 06 May 2024 14:53:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amacapital-net.20230601.gappssmtp.com; s=20230601; t=1715032414; x=1715637214; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=EeUVpQq/22mOYcKReCK3JqvU1k/TRLUaHjaQZvRF2NE=; b=b9etqhUYq9W3jFOnartK2afBDMImdFDpjRaatf2DWlTDDyA1xcnQQiz2LkJVHLs8tW jYQN4mbotk1z7KLgDVp2dWsxEFKpyfbOiLsbJwmNH8r/wntd4XEujLjyfukjD/Ul/JyY vgdXTZkzFtiQG+/Ion8mI6XwrnvxIXUty0M81dND19jr5ybsPPqaVwETQVoi+ZP/DCC2 Ij53kotdedrRJV/iWAoHodKJwpds5Jpe/nSm7J36zT9oGg1lwPI+pPtjZkZroUJdtLW1 A+i/CiJrrX+OmHQ+yiQw/p3d97+aFCmWvJgeFGziFD69DQJkD0XA5ZDH3KqLB71+lQWt Fzog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715032414; x=1715637214; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=EeUVpQq/22mOYcKReCK3JqvU1k/TRLUaHjaQZvRF2NE=; b=EIizkURM9q6Z9doYRjXurStImmyLYgpRTyD+DIkDbToMB7ic1VApF5QgNm3T9iLaSh 27Qov4J+ieinVNznJnRjdIHHnhvGvxvHz8FTLn7LH/8URN/jiVPI/TyUFWyYnHimd2ts JAOMjyb/6hauwZ+iVhillfSsRhQaVqtpHtsf24ms6IjjXShzhdtmJdrOldOB9HmLGcSR v7gH7ApXOvhrdvxyIL94IahTUWPqRc77gUB+ZlyPJ7HLxjcU+UAlKsFn3x7HspLWDvrP COXQvW3mDwWCFdFUbyjKLYMPlDQbz7kOX3yK9iKfBeGcFk852xTWEuMC533J8e7nL7TR Q2bQ== X-Forwarded-Encrypted: i=1; AJvYcCVfmKpeiVo+4bx06LdPXIfPd8abkbrJjdxc7SThLw0EyjT8XzpGfa/H9q0AZMAh9gMM/PllVUYZDtxs3C7kHOw3kzZGbRE9Ol9YRha7 X-Gm-Message-State: AOJu0Yy3Umwt9JvNlqmIDXdXxNd4QXsqVthiVON+zMUdcCWcYhDq+iUt Y9bqyxrrsB0zpXZ00IpgEhSY9SwDmcbHdB6SIqASP4MwudlvEYRFg9jMckFmnPdmcmRYHlcgpDk 85lMkmHN3rqInHnNF9DLxwDTJ95OhqBHg8ojY X-Received: by 2002:a05:6122:3089:b0:4da:9d3e:a7df with SMTP id cd9-20020a056122308900b004da9d3ea7dfmr11204998vkb.5.1715032414464; Mon, 06 May 2024 14:53:34 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240426133310.1159976-1-stsp2@yandex.ru> <20240428.171236-tangy.giblet.idle.helpline-y9LqufL7EAAV@cyphar.com> In-Reply-To: From: Andy Lutomirski Date: Mon, 6 May 2024 14:53:23 -0700 Message-ID: Subject: Re: [PATCH v5 0/3] implement OA2_CRED_INHERIT flag for openat2() To: David Laight Cc: Aleksa Sarai , Stas Sergeev , "Serge E. Hallyn" , "linux-kernel@vger.kernel.org" , Stefan Metzmacher , Eric Biederman , Alexander Viro , Andy Lutomirski , Christian Brauner , Jan Kara , Jeff Layton , Chuck Lever , Alexander Aring , "linux-fsdevel@vger.kernel.org" , "linux-api@vger.kernel.org" , Paolo Bonzini , =?UTF-8?Q?Christian_G=C3=B6ttsche?= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, May 6, 2024 at 12:35=E2=80=AFPM David Laight wrote: > > ... > > So I want a way to give *an entire container* access to a directory. > > Classic UNIX DAC is just *wrong* for this use case. Maybe idmaps > > could learn a way to squash multiple ids down to one. Or maybe > > something like my silly credential-capturing mount proposal could > > work. But the status quo is not actually amazing IMO. > > Isn't that what gids are for :-) I dunno. How, exactly, is a regular non-root user of a Linux computer supposed to configure gids in their home directory so that a container (which uses subgids, possibly dynamically allocated) gets access to the correct thing? And why should that poor user need to think about this at all? --Andy