From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from atuin.qyliss.net (localhost [IPv6:::1]) by atuin.qyliss.net (Postfix) with ESMTP id 6F6E49F1E; Tue, 02 Dec 2025 13:15:13 +0000 (UTC) Received: by atuin.qyliss.net (Postfix, from userid 993) id 380749F0D; Tue, 02 Dec 2025 13:15:11 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on atuin.qyliss.net X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DMARC_MISSING,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=4.0.1 Received: from fout-b8-smtp.messagingengine.com (fout-b8-smtp.messagingengine.com [202.12.124.151]) by atuin.qyliss.net (Postfix) with ESMTPS id 2907A9F0B for ; Tue, 02 Dec 2025 13:15:09 +0000 (UTC) Received: from phl-compute-11.internal (phl-compute-11.internal [10.202.2.51]) by mailfout.stl.internal (Postfix) with ESMTP id A4D571D00216; Tue, 2 Dec 2025 08:15:05 -0500 (EST) Received: from phl-mailfrontend-01 ([10.202.2.162]) by phl-compute-11.internal (MEProxy); Tue, 02 Dec 2025 08:15:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alyssa.is; h=cc :cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm3; t=1764681305; x=1764767705; bh=CaLvqz1lI+ fxoEYg2s2RW0LyiU+WwsUqjpAwT8lCxcc=; b=AHy63eho5emWKigGsTSid+4FNc 0ZN3Wzq01ijSEPEbQPiLyB03/we9X/HYBdZSUratHdWHDXJSYYjbOAtMFvEf7I26 xW7UhV74MQDhlDcvMJ5kr49RJlZppehG7BjwKObaSrSp34dANvBvNFzUrI39+KOu l2eMUiJ8gDabtU59+I9Cu7ZLp1MrJphj07M2wUC1MBuwoO171LFnjmtMnG0N1R6p MUfLfr/V0pP3wqGBBYigPcU+e/HbIShNEyukToi3b1ZGWVI+aA1EYVfHsBfTJSI+ MKUijIA0yjoX8cqJaFUko05WshzyumVf1JoknGJ5tVK7dPlB4NB9zY3ug7oQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1764681305; x=1764767705; bh=CaLvqz1lI+fxoEYg2s2RW0LyiU+WwsUqjpA wT8lCxcc=; b=uBBMa1zFExHpZ3Efc2Bx6IUpvcqiDI0Pq0eDFxZYo7stYDtkeRk k8Q43iGVgUfUmKHgIiuazhfYdw8YYtubi69YVhs6axf8KQj2SoyDbuBrcJDDJ4aU 3LgIBpcAcKhuvzlsJPitB2eSQBVW+tMPs96BVMPeIHtAchaXMWdiWuhrv7qLk6oT WGvwP567nHkCbTZSCPqKLvtR2jvByHF+v//zLrII9ygUx9gnZ0t5JZx0MdaLRQmj wFF5671lsmpfFjV12I7rDdwpUPBex190cicpAN4T46zQMyWs7We26icN1nON1xgC zcNHfWVI0LkwmXELhMYHE4bIM/xTLBp8IDQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefgedrtddtgddvudcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpuffrtefokffrpgfnqfghnecuuegrihhl ohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpe fhvfevufgjfhffkfggtgesghdtreertddtjeenucfhrhhomheptehlhihsshgrucftohhs shcuoehhihesrghlhihsshgrrdhisheqnecuggftrfgrthhtvghrnhephfetiefggfekhf etjeekffdvgedvgefhiedtieelgfdujeeftdetveffvdelfeeunecuffhomhgrihhnpehs phgvtghtrhhumhdqohhsrdhorhhgnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrg hmpehmrghilhhfrhhomhephhhisegrlhihshhsrgdrihhspdhnsggprhgtphhtthhopedv pdhmohguvgepshhmthhpohhuthdprhgtphhtthhopeguvghmihhosggvnhhouhhrsehgmh grihhlrdgtohhmpdhrtghpthhtohepuggvvhgvlhesshhpvggtthhruhhmqdhoshdrohhr gh X-ME-Proxy: Feedback-ID: i12284293:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 2 Dec 2025 08:15:04 -0500 (EST) Received: by fw12.qyliss.net (Postfix, from userid 1000) id 5B5B340463CC; Tue, 02 Dec 2025 14:14:47 +0100 (CET) From: Alyssa Ross To: Demi Marie Obenour Subject: Re: [PATCH v2 0/4] Partially sandbox Cloud Hypervisor, crosvm, virtiofsd, and the router In-Reply-To: <20251201-sandbox-v2-0-9f4e58252c2b@gmail.com> References: <20251129-sandbox-v1-1-6dab926504d3@gmail.com> <20251201-sandbox-v2-0-9f4e58252c2b@gmail.com> Date: Tue, 02 Dec 2025 14:14:36 +0100 Message-ID: <878qflf2kj.fsf@alyssa.is> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Message-ID-Hash: TJLKQYZ564XWSYJFYNUAMPE2WJMKQWXK X-Message-ID-Hash: TJLKQYZ564XWSYJFYNUAMPE2WJMKQWXK X-MailFrom: hi@alyssa.is X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-devel.spectrum-os.org-0; header-match-devel.spectrum-os.org-1; header-match-devel.spectrum-os.org-2; header-match-devel.spectrum-os.org-3; header-match-devel.spectrum-os.org-4; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Spectrum OS Development X-Mailman-Version: 3.3.9 Precedence: list List-Id: Patches and low-level development discussion Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Demi Marie Obenour writes: > This restricts the access of these programs to the system. Seccomp is > not enabled, though, and the processes still run as root. Full > sandboxing needs additional work. In particular, Cloud Hypervisor > should receive access to VFIO devices via file descriptor passing. > > Sandboxing Cloud Hypervisor requires the use of sh, as there is no s6 > or execline program to increase hard resource limits. Yes there is! It's poorly named though =E2=80=94 presumably the hard limit functionality was added later. We now do this in application VMs for Pipewire: https://spectrum-os.org/git/spectrum/tree/img/app/image/usr/bin/init?id=3Dd= ecd54105e6a54fee737ea436fcb1642141b337e#n5 > D-Bus and the portal are not sandboxed. They have full access to all > user files by design, so a breach of either is catastrophic no matter > what. Furthermore, sandboxing them even slightly proved very > difficult. > > Signed-off-by: Demi Marie Obenour > --- > Changes in v2: > - Sandbox Cloud Hypervisor, virtiofsd, and the router > - Link to v1: https://spectrum-os.org/lists/archives/spectrum-devel/20251= 129-sandbox-v1-1-6dab926504d3@gmail.com > > --- > Demi Marie Obenour (4): > host/rootfs: Sandbox crosvm > host/rootfs: Sandbox router > host/rootfs: Sandbox virtiofsd > host/rootfs: Sandbox Cloud Hypervisor > > host/rootfs/default.nix | 4 +-- > .../template/data/service/spectrum-router/run | 19 +++++++++++-- > .../template/data/service/vhost-user-fs/run | 28 ++++++++++++++++= -- > .../template/data/service/vhost-user-gpu/run | 24 +++++++++++++++- > .../image/etc/udev/rules.d/99-spectrum.rules | 3 ++ > host/rootfs/image/usr/bin/run-vmm | 33 ++++++++++++++++= +++--- > 6 files changed, 98 insertions(+), 13 deletions(-) > --- > base-commit: 44f32b7a4b3cfbb4046447318e6753dd0eb71add > change-id: 20251129-sandbox-5a42a6a41b59 > > --=20 > Sincerely, > Demi Marie Obenour (she/her/hers) --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQQGoGac7QfI+H5ZtFCZddwkt31pFQUCaS7mPAAKCRCZddwkt31p FTMYAQCDM5ajEHPBYGoxmebHriv5V0Zf2rknfqWjLeNmkgWbEAD/d80aAwidHrWZ w1IbfNrWDQ0plm95OuvOk8PPODHXBg4= =Mqyz -----END PGP SIGNATURE----- --=-=-=--