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 E34DE6DD6; Wed, 22 Jul 2026 08:18:13 +0000 (UTC) Received: by atuin.qyliss.net (Postfix, from userid 993) id 59E5C6DBC; Wed, 22 Jul 2026 08:18: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 fhigh-b2-smtp.messagingengine.com (fhigh-b2-smtp.messagingengine.com [202.12.124.153]) by atuin.qyliss.net (Postfix) with ESMTPS id 0C67D6DBA for ; Wed, 22 Jul 2026 08:18:10 +0000 (UTC) Received: from phl-compute-06.internal (phl-compute-06.internal [10.202.2.46]) by mailfhigh.stl.internal (Postfix) with ESMTP id 7B9AB7A012E; Wed, 22 Jul 2026 04:18:08 -0400 (EDT) Received: from phl-frontend-04 ([10.202.2.163]) by phl-compute-06.internal (MEProxy); Wed, 22 Jul 2026 04:18:08 -0400 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=fm1; t=1784708288; x=1784794688; bh=wtX9DXNbK0 PRBzbclcVYrtzQN+MCQyAnXZz7bChdyIc=; b=AapLZRjhF0wvx2fqnnmqxme/0z 72WrOmLpPM2WjhQs6okUJwLdofdEwPImWUb3OYmt36EREJ2ZXOPbtSa8MvRmrDLO g348RedjygJteJ5NzaXNkR9AO97WtY8bLoncZ44LI1w/cKfzCtp/y6INr9077fru nhcqnn761hk6uoIOi8BxAdNtWjuzhuojPKdV0w95HJdKsi+U8su5/EhXZxLpnJzv 6ZK4hEzbmObuKeXijp73tHj8Qfhb450gl2IJBhrKauO3UoA4vmoCstYtOBCobu9c vMs1x3qMS++RHHWtauUVZ84eqVge5FX+DkMGEev4dAjdswXxjvwZcO9KHHRA== 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=fm2; t= 1784708288; x=1784794688; bh=wtX9DXNbK0PRBzbclcVYrtzQN+MCQyAnXZz 7bChdyIc=; b=K1ReFOfCaBYVDx6vq6pqGyta5fsPBHqZ7+aUXEzdMknTZEGAiii Dyutse1pLdOisaJh7wgjdTpwSMQur1DEh3d8GHVWXnSEi6xDb7PFDsEF0Rir7ocP Q+ebMSjOfn2YHFesO304v7oXIRwG8yj4Pw5py/WnexiSwqhHPo3lPWkf1COlBlfY VkpjdVQwQ2z78fmsp6VSNETl25DpNWW/6rP3TdpqxY3m5tIw/KTWQNzbR9K4I0ld /sFWhppt5t5Zpzak0hLqBKMvxLL++qWtSinqMFT1xboSFvo9YMHlBgJ+TnS9UkGj H5EMKhbVskGJTmtHz73ZHcAYp11o/jWE4lw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: dmFkZTGzxBdlk8gdAm2/MIj7w21aiIRtkHYPBWjxREORKrmj+NJQORCmV9i0YG5uJd8eU+ /q+HApVzUdnI8jTYeuzmtyvzmb0Irm/PHdiOi51Sy56Hw0xjCU70u3LsyXnt6gWmL+sQ41 EZkhtlrvnFqewABnXiocuApS28I9JIjk79qaZ7/Fec0ftKxRKOJoIU/fgNWaFsVNNSJyjE oIvhMPL/0Jk0X9fkgbFH/w3EN1rDue1a+Cfa1ROjVr0nYD8PRzembGSaZxTrQqrDgjVRib oMBH8bpNFjKzM4o8zFSYfkRUUXf7K2BSY+4Vqs6DACSW5pGI5TkHeVyUXHQCPfpJypqUWB Mb6gGlvxABvCjieyj86hjzGwcDnjVyaSVUAkxIqu8MOCy2Yh7O3Y3JtIIHM4y1WlfJ7oyn oEkrQiDsy+TXpK1jnRzewr+3/i7Yintnq1OxPvRJvHPGyACWdLUUmmzxYY6cA6B8aTMW6f R5MKXgeoeptNHZwJAc878StRipYUpkmOHwPWptoblWqO5s72gZp7AWpluRx8rhT6QYYSlK /c7svi5BIgXwe+h4rqu0HLtWQodDgVilyS5KLMB1kiQzIzYC/jADnF3lIOCKMLBpLmVvhu ooj6cG/RlXydvJQAXg7NQ/yHvwmJ9UZdtIisB9V5eblAO9Dj0pGxoef+xOHw X-ME-Proxy: Feedback-ID: i12284293:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 22 Jul 2026 04:18:08 -0400 (EDT) Received: by mbp.qyliss.net (Postfix, from userid 1000) id EBE6D89680B6; Wed, 22 Jul 2026 10:18:05 +0200 (CEST) From: Alyssa Ross To: Demi Marie Obenour Subject: Re: Why is /run/vm/by-id/${VM} writable by the VMM? In-Reply-To: References: <87ech71crf.fsf@alyssa.is> <0d8076ca-dd4d-42c2-9806-0f78841ae397@gmail.com> <8733xkqe22.fsf@alyssa.is> <87se5cl45p.fsf@alyssa.is> Date: Wed, 22 Jul 2026 10:18:05 +0200 Message-ID: <87wluntp36.fsf@alyssa.is> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Message-ID-Hash: AJKK3YK2FQPDOYBCQQC2EOVLTYD5CQ5U X-Message-ID-Hash: AJKK3YK2FQPDOYBCQQC2EOVLTYD5CQ5U X-MailFrom: hi@alyssa.is X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; 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; emergency; member-moderation; 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.10 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 Content-Transfer-Encoding: quoted-printable Demi Marie Obenour writes: > On 7/21/26 12:05, Alyssa Ross wrote: >> Demi Marie Obenour writes: >>=20 >>> On 7/15/26 14:54, Alyssa Ross wrote: >>>> Demi Marie Obenour writes: >>>> >>>>> On 7/13/26 05:04, Alyssa Ross wrote: >>>>>> Demi Marie Obenour writes: >>>>>> >>>>>>> This seems to be a fairly significant hole in the VMM's sandbox. >>>>>>> Various code operates in that directory and isn't secure against >>>>>>> symlink attacks. >>>>>>> >>>>>>> Does the VMM really need write access to that directory? Could it >>>>>>> be given access to a subdirectory that is mounted "nosymfollow"? >>>>>> >>>>>> I think it's just so it can create e.g. the serial file. That could >>>>>> indeed be moved to a subdirectory. The ideal solution is of course = for >>>>>> Cloud Hypervisor to be able to accept every file it would otherwise >>>>>> create as an open file descriptor, which I expect will happen >>>>>> eventually. >>>>> >>>>> Should it be moved to a subdirectory for now? That would make the >>>>> sandbox meaningful in practice. >>>> >>>> I suppose it could be. Might make more sense to dedicate efforts >>>> towards fixing Cloud Hypervisor to accept file descriptors for the ~2 >>>> paths it currently needs to create, though. (That's obviously more >>>> work, but also more useful.) If we were to work around this in >>>> Spectrum, we could keep symlinks outside the directory pointing into i= t, >>>> to keep paths nice and avoid churn once we can put them back in the >>>> parent directory. >>> >>> Do you happen to know which paths these are? >>=20 >> I think it might just be "serial"? Not sure. > > How difficult would it be to modify Cloud Hypervisor so this is passed > as a file descriptor? I don't expect it would be very hard. It's recently been done for e.g. VFIO FDs, but I also don't think I have any special knowledge here that you don't? --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRV/neXydHjZma5XLJbRZGEIw/wogUCamB8vQAKCRBbRZGEIw/w opb8AQD0dzJmKoxCwa2VXUxPCo9vf3rQcn6FgrF+ATb/iut3VwD5AQhiJkKyl1qD grW4MPdHfP6aQrM43xXQI/7wKZvPeAY= =dgvb -----END PGP SIGNATURE----- --=-=-=--