Re: [🚨ext] Re: [PATCH v3 0/2] virt: tdx-guest: Fix and speed up the wait for a Quote
From: Edgecombe, Rick P
Date: Tue Nov 24 2026 - 13:13:04 EST
On Wed, 2026-11-18 at 14:55 +0000, Moe Mahhouk wrote:
> On Wed, 2026-11-18 at 01:28 +0000, Edgecombe, Rick P wrote:
> > I'd think a simpler shortening of the time would be better than something more
> > advanced. But...
>
> OK. In v4, patch 2 will replace the backoff with a fixed 10 ms sleep.
> Patch 1 stays as it is. It fixes the timeout check and is marked for
> stable, so it could also go in on its own.
Ok.
>
> > Shouldn't attested TLS just be used to set up some other key such that
> > subsequent connections can be as fast as normal TLS? 0.1s is still kind of slow.
>
> The 0.1 s was the total for ten clients connecting at once. Each Quote
> took about 8 ms with v3 of patch 2 (median of 120 back-to-back Quotes at
> HZ=250), and quote_lock runs them one after the other.
>
> Our HTTP proxy already does part of this. A client keeps its attested
> connection open and sends all its requests over it, so it needs one
> Quote per connection, not per request. What is left is the first
> connection of each client. Many clients can arrive at once, for example
> after the TD restarts. Today the last of N clients waits about N
> seconds.
>
> We don't trust a key from an earlier attestation for new connections.
> If a later connection relied only on such a key, a leaked key would be
> enough to pass as the TD without any Quote. The recent relay attacks on
> attested TLS used this kind of gap. In CVE-2026-108269 (CVSS 9.1) the
> Quote was bound to the TLS key and a client nonce but not to the
> session, so an attacker with the TLS private key could relay a genuine
> Quote onto its own connection. Binding each Quote to keying material
> exported from that session closes this. The exported value is unique to
> each handshake, so it also serves as the nonce.
Thanks for sharing. The case is "an attacker with the TLS private key" and a bug
in a client library? It sounds like a pretty aggressive threat model. I'm still
not sure quoting is setup for this kind of thing from a performance perspective.
But very interesting to hear about the use case.
>
> > In the end I think quote based attested TLS is not normally expected to be fast.
> > So is this trying to optimize the wrong thing?
>
> It does not need to be as fast as plain TLS. But the second is not the
> cost of attestation. With a local QGS the Quote is ready a few
> milliseconds after the request, but the driver does not check again for
> a full second. Any user of configfs-tsm on TDX pays that, whatever runs
> on top. The patch shortens that wait. It does not try to make the Quote
> itself faster.
>
> If that works for you, I will send v4 with the fixed interval.
Yea, let's just go with the polling fix and the faster rate. It seems the
default is too high based on the assumption that users would rather spend CPU
cycles then wait when getting a quote.
And sorry for the slow responses. I was waiting for someone else to chime in but
it seems they will not be able to.