From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: passt.top; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: passt.top; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=RGyMps4t; dkim-atps=neutral Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by passt.top (Postfix) with ESMTPS id 0F2515A026F for ; Tue, 07 Oct 2025 18:49:19 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1759855759; h=from:from: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: in-reply-to:in-reply-to:references:references; bh=bZOeNX88G6LJr/NjyKOvI5dUQxJu++Ltg7HlfHR1KXQ=; b=RGyMps4tbiSyGXcVn1PxuJstzPELuKeNZdRTwU6tZIa7REYSFAWnnCp/XcJJoJjVePxscn LK7ebh+6PPwlyr1+t+mkt6gy0RrKX5cTFiP4Li0NetrGRr19Ww7DzTn5IOYdpegioat0Vg GhJ19z3Uz6lMQ/IduBhPi4u2vvWzULk= Received: from mail-wm1-f72.google.com (mail-wm1-f72.google.com [209.85.128.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-58-rZ-nB9DFMBajt8k9uGIj-Q-1; Tue, 07 Oct 2025 12:49:17 -0400 X-MC-Unique: rZ-nB9DFMBajt8k9uGIj-Q-1 X-Mimecast-MFC-AGG-ID: rZ-nB9DFMBajt8k9uGIj-Q_1759855756 Received: by mail-wm1-f72.google.com with SMTP id 5b1f17b1804b1-46eee58d405so11130745e9.1 for ; Tue, 07 Oct 2025 09:49:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1759855756; x=1760460556; h=content-transfer-encoding:mime-version:organization:references :in-reply-to:message-id:subject:cc:to:from:date:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=bZOeNX88G6LJr/NjyKOvI5dUQxJu++Ltg7HlfHR1KXQ=; b=PyZb+XrYueW2dz6bEvpybX0KbL1dnVRev8BpfNWpfUe7mdX1aRpRLJyGskudjM8MO/ q3gzcMOdSNirlSUJaZsk4n2eQ7FQZsyziJCWsyzyieJbuI5elE1QnDfykGzQh8LEz2Fw HNDlVtY3Ig7r59rhffC9HYJrb0ldvivUPqtPpIxPzM48CwowrqNXq6kl++iNX9RPEfnC WNxAFj773VTaqwY1/BKn3iYbc8pS16/zcUuhLnXd+nHWRjYxpGco5wmajDRXGv/OybVo 76IZXFLmChPlN9ZMcl7buJOj+KyHHaz+TlcfH3LgqqKPbrwntjQZw077jfcDqcZ7z/3S 9nhA== X-Forwarded-Encrypted: i=1; AJvYcCX7tcyPc2yCXa0MJQTWUOKxElcXQAHAT3640D2VgPbsmECSkYtaTq+hsdWN/IKrZVjBEH+v+Cs8p7A=@passt.top X-Gm-Message-State: AOJu0Yy8J+HUEYXa7294i6NJpw6TOu/+9+2Iw+NwLyVNnehXX1eRJe/4 GhIyihb+iQsvdY1pb442A9MeQRei909DhCBXp0rTn16uKLM0tdi377Jn0BnEuGGWuRpVnEZvXWM Kq+RXkocUpd9417f/Lj96L+uKsLU3LVlILmFVxgBe/4rFKDYwul2DiA== X-Gm-Gg: ASbGncvobAHWvvMatzKGjUm+/SaAaHZJJdd90RpQXVfkFus4cilcMLpg5/YtgJ90ILG r+uMLtqr9dWs2glzsOUCxMWWFq4rsmTv8rz9IZZsHDEGzlkpNs07+zbTjllFOv560LKJAmnL3f6 UKvQKNooEA98GHrPqRpDdHF2Iw9c2Brj/11j4WJcsioXGJwbdd7lqgYFyinxyDAGQiAa4JlV5JV ERu0y61r6CnT7tF5UgHeU2ex9Ss+KCZIKwZHnYuS+pJCunViX8ZmM7GldUIN/2GA6xVR38SE8IG IizONsYXTRLEt1iUujnK9CSXjpfdSZlPlfzPn6VUSyi0Edrp5wO7hOl6 X-Received: by 2002:a05:600c:4f92:b0:45f:27a3:6e0e with SMTP id 5b1f17b1804b1-46fa9aa20c4mr2057525e9.14.1759855756216; Tue, 07 Oct 2025 09:49:16 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHa7GdiVoSwBzfPU7uKypQwyzhipvrn8zcYOoHqZWysNjYujEEKii1szyl92JfZWq9pznJEYQ== X-Received: by 2002:a05:600c:4f92:b0:45f:27a3:6e0e with SMTP id 5b1f17b1804b1-46fa9aa20c4mr2057215e9.14.1759855755577; Tue, 07 Oct 2025 09:49:15 -0700 (PDT) Received: from maya.myfinge.rs (ifcgrfdd.trafficplex.cloud. [2a10:fc81:a806:d6a9::1]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-46fa3a0d17fsm20537565e9.4.2025.10.07.09.49.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Oct 2025 09:49:15 -0700 (PDT) Date: Tue, 7 Oct 2025 18:49:13 +0200 From: Stefano Brivio To: Cole Robinson Subject: Re: [PATCH] isolation: keep CAP_DAC_OVERRIDE initially Message-ID: <20251007184913.43e897a8@elisabeth> In-Reply-To: <229a2d1d-f899-4eae-a23c-d0613d6f2593@redhat.com> References: <8635494bf4747935bc2179bdb37c8c2cbbe4ed55.1759839307.git.crobinso@redhat.com> <20251007180232.328feebc@elisabeth> <229a2d1d-f899-4eae-a23c-d0613d6f2593@redhat.com> Organization: Red Hat X-Mailer: Claws Mail 4.2.0 (GTK 3.24.49; x86_64-pc-linux-gnu) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: Emb2ObnZB4Oe-O5HUY6uJ9bnAqI02Y-SuWjIYzJ5vYQ_1759855756 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Message-ID-Hash: 2XGQRVN3XVXRBEK4WRPXOMT5DHVA34WX X-Message-ID-Hash: 2XGQRVN3XVXRBEK4WRPXOMT5DHVA34WX X-MailFrom: sbrivio@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: David Gibson , passt-dev@passt.top, "Richard W.M. Jones" , Yumei Huang X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Tue, 7 Oct 2025 12:43:30 -0400 Cole Robinson wrote: > On 10/7/25 12:02 PM, Stefano Brivio wrote: > > [Cc: Yumei as this is somewhat related to > > https://archives.passt.top/passt-dev/20250926011714.5978-1-yuhuang@redhat.com/, > > and David as he wrote most of this part] > > > > On Tue, 7 Oct 2025 08:16:39 -0400 > > Cole Robinson wrote: > > > >> Reproducer that I'd expect to work > >> > >> $ cd $HOME > >> $ sudo passt --runas $UID --socket foo.sock > >> Failed to bind UNIX domain socket: Permission denied > >> > >> A more practical example is for libguestfs apps when run as user=root. > >> > >> + libguestfs connects to libvirt qemu:///system > >> + libvirt qemu:///system defaults to user=qemu. > >> + chowns passt runtime dir to user=qemu > >> + libguestfs instead requests the VM run as user=root > >> + patches in progress but we are blocked by this issue > >> + passt is launched as root, but can't open socket in passt dir. > >> > >> Obviously libvirt needs improvements too. > >> But it seems like this is a defect as well. > > > > Thanks for the patch! I think it's absolutely unproblematic to keep > > CAP_DAC_OVERRIDE for a moment at the beginning. Did you figure out > > exactly why it's needed by the way? > > > > Last line in the list above should read: > > + passt is launched as root, but can't open socket in passt dir > because it's owned by qemu.qemu ...at this point, can you perhaps come up with a complete commit message also including the details Rich explained / reported? No need to repost. On the other hand it's a single patch so if you have a moment you might as well... > > >> Signed-off-by: Cole Robinson > > > > Should we add: > > > > Link: https://github.com/libguestfs/libguestfs/pull/218 > > > > ? Or it's misleading, or you omitted it for any other reason? > > > > Works for me! I did not intentionally omit it > > Thanks, > Cole > -- Stefano