rng: add builtin rng backend model
The builtin rng backend uses getrandom syscall to generate random, no external rng source needed, introduced from libvirt v6.1.0. Reviewed-by: Cole Robinson <crobinso@redhat.com> Signed-off-by: Han Han <hhan@redhat.com>
This commit is contained in:
parent
f6eee380a2
commit
f34f73622d
|
@ -1722,7 +1722,7 @@ Use --tpm=? to see a list of all available sub options. Complete details at L<ht
|
|||
|
||||
Configure a virtual RNG device.
|
||||
|
||||
Type can be B<random> or B<egd>.
|
||||
Type can be B<random>, B<egd> or B<builtin>.
|
||||
|
||||
If the specified type is B<random> then these values must
|
||||
be specified:
|
||||
|
@ -1768,6 +1768,8 @@ B<udp> and backend_mode is B<bind>.
|
|||
|
||||
=back
|
||||
|
||||
If the specified type is B<builtin>, B<backend> is not required.
|
||||
|
||||
An example invocation:
|
||||
|
||||
=over 4
|
||||
|
@ -1781,6 +1783,10 @@ Connect to localhost to the TCP port 8000 to get entropy data.
|
|||
Use the /dev/random device to get entropy data, this form implicitly uses the
|
||||
"random" model.
|
||||
|
||||
=item B<--rng builtin>
|
||||
|
||||
Use the builtin rng device to get entropy data.
|
||||
|
||||
Use --rng=? to see a list of all available sub options. Complete details at L<https://libvirt.org/formatdomain.html#elementsRng>
|
||||
|
||||
=back
|
||||
|
|
|
@ -573,6 +573,8 @@ class vmmAddHardware(vmmGObjectUI):
|
|||
return _("Random")
|
||||
if rng_type == DeviceRng.TYPE_EGD:
|
||||
return _("Entropy Gathering Daemon")
|
||||
if rng_type == DeviceRng.TYPE_BUILTIN:
|
||||
return _("Builtin RNG")
|
||||
return rng_type
|
||||
|
||||
@staticmethod
|
||||
|
|
|
@ -14,6 +14,7 @@ class DeviceRng(Device):
|
|||
|
||||
TYPE_RANDOM = "random"
|
||||
TYPE_EGD = "egd"
|
||||
TYPE_BUILTIN = "builtin"
|
||||
|
||||
model = XMLProperty("./@model")
|
||||
|
||||
|
|
Loading…
Reference in New Issue