Thread (20 messages) 20 messages, 9 authors, 2020-10-20

Re: [PATCH] drivers/virt: vmgenid: add vm generation id driver

From: Willy Tarreau <w@1wt.eu>
Date: 2020-10-17 07:18:03
Also in: kvm, linux-doc, linux-s390, lkml, qemu-devel

Possibly related (same subject, not in this thread)

On Sat, Oct 17, 2020 at 08:55:34AM +0200, Jann Horn wrote:
My suggestion is to use a counter *in the UAPI*, not in the hypervisor
protocol. (And as long as that counter can only miss increments in a
cryptographically negligible fraction of cases, everything's fine.)
OK I got it now and I agree.
quoted
If what is sought is pure
randomness (in the sense that it's unpredictable, which I don't think
is needed here), then randoms are better.
And this is what *the hypervisor protocol* gives us (which could be
very useful for reseeding the kernel RNG).
As an external source, yes very likely, as long as it's not trivially
observable by everyone under the same hypervisor :-)
quoted
Now the initial needs in the forwarded message are not entirely clear
to me but I wanted to rule out the apparent mismatch between the expressed
needs for uniqueness and the proposed solutions solely based on randomness.
Sure, from a theoretical standpoint, it would be a little bit nicer if
the hypervisor protocol included a generation number along with the
128-bit random value. But AFAIU it doesn't, so if we want this to just
work under Microsoft's existing hypervisor, we'll have to make do with
checking whether the random value changed. :P
OK got it, thanks for the explanation!

Willy
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help