qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
To: "Daniel P. Berrangé" <berrange@redhat.com>
Cc: Tom Lendacky <thomas.lendacky@amd.com>,
	Ashish Kalra <ashish.kalra@amd.com>,
	Brijesh Singh <brijesh.singh@amd.com>,
	James Bottomley <jejb@linux.ibm.com>,
	Marcelo Tosatti <mtosatti@redhat.com>,
	qemu-devel@nongnu.org, Markus Armbruster <armbru@redhat.com>,
	Dov Murik <dovmurik@linux.ibm.com>,
	Tobin Feldman-Fitzthum <tobin@linux.ibm.com>,
	Paolo Bonzini <pbonzini@redhat.com>,
	Eric Blake <eblake@redhat.com>
Subject: Re: [PATCH] qapi, i386/sev: Add debug-launch-digest to launch-measure response
Date: Mon, 14 Feb 2022 10:35:21 +0000	[thread overview]
Message-ID: <YgowaU95oX1qXvIN@work-vm> (raw)
In-Reply-To: <YgY1QU/9JfwvFT+5@redhat.com>

* Daniel P. Berrangé (berrange@redhat.com) wrote:
> On Thu, Feb 10, 2022 at 07:39:01PM +0000, Dr. David Alan Gilbert wrote:
> > * Daniel P. Berrangé (berrange@redhat.com) wrote:
> > > I wonder if we're thinking of this at the wrong level though. Does
> > > it actually need to be QEMU providing this info to the guest owner ?
> > > 
> > > Guest owners aren't going to be interacting with QEMU / QMP directly,
> > > nor are they likely to be interacting with libvirt directly. Their
> > > way into the public cloud will be via some high level API. eg the
> > > OpenStack Nova REST API, or the IBM Cloud API (whatever that may
> > > be). This high level mgmt infra is likely what is deciding which
> > > of the 'N' possible OVMF builds to pick for a given VM launch. It
> > > could easily just expose the full OVMF data to the user via its
> > > own API regardless of what query-sev does.
> > > 
> > > Similarly if the cloud is choosing which kernel, out of N possible
> > > kernels to boot with, they could expose the raw kernel data somewhere
> > > in their API - we don't neccessarily need to expose that from QEMU.
> > 
> > It gets more interesting where it's the guest which picks the
> > kernel/initrd; imagine the setup where the cloud reads the kernel/initrd
> > from the guest disk and passes that to qemu; one of the update ideas
> > would be just to let the guest update from a repo at it's own pace;
> > so the attestor doesn't know whether to expect a new or old kernel
> > from the guest; but it does know it should be one of the approved
> > set of kernels.
> 
> So that scenario would effectively be the old Xen style pygrub where
> you have some script on the host to pull the kernel/initrd out of
> the guest /boot.

Right.

> On the plus side that would enable you to use a "normal" guest disk
> image with unencrypted /boot, instead of encrypting everything.

Yes; the other plus is that you don't need the guest to send update
information back to the attestor to tell it when it's done an update;
that's potentially a big simplification on an untrusted interface.

> The risk though is that you need a strong guarantee that the *only* data
> from /boot that is used is the kernel+initrd+cmdline that get included
> in the measurement. If the guest boot process reads anything else from
> /boot then your confidentiality is potentially doomed. This feels like
> quite a risky setup, as I don't know how you'd achieve the high level of
> confidence that stuff in /boot isn't going to cause danger to the guest
> during boot, or after boot.

Which I think pygrub type things found out the hard way; but as long as
you copy from /boot, attest on the data you use and then boot using the
data you attested you should be OK.

Dave

> Regards,
> Daniel
> -- 
> |: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
> |: https://libvirt.org         -o-            https://fstop138.berrange.com :|
> |: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|
> 
-- 
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK



  reply	other threads:[~2022-02-14 10:36 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-31 11:15 [PATCH] qapi, i386/sev: Add debug-launch-digest to launch-measure response Dov Murik
2022-01-31 11:44 ` Daniel P. Berrangé
2022-01-31 13:38   ` Dov Murik
2022-01-31 14:26     ` Daniel P. Berrangé
2022-02-01 21:43       ` Tobin Feldman-Fitzthum
2022-02-10 19:39       ` Dr. David Alan Gilbert
2022-02-11 10:06         ` Daniel P. Berrangé
2022-02-14 10:35           ` Dr. David Alan Gilbert [this message]
2022-02-14  8:15       ` Dov Murik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YgowaU95oX1qXvIN@work-vm \
    --to=dgilbert@redhat.com \
    --cc=armbru@redhat.com \
    --cc=ashish.kalra@amd.com \
    --cc=berrange@redhat.com \
    --cc=brijesh.singh@amd.com \
    --cc=dovmurik@linux.ibm.com \
    --cc=eblake@redhat.com \
    --cc=jejb@linux.ibm.com \
    --cc=mtosatti@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=thomas.lendacky@amd.com \
    --cc=tobin@linux.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).