Bumps the vhost-device group with 22 updates in the / directory: | Package | From | To | | --- | --- | --- | | [clap](https://github.com/clap-rs/clap) | `4.5.9` | `4.5.13` | | [env_logger](https://github.com/rust-cli/env_logger) | `0.11.3` | `0.11.5` | | [tempfile](https://github.com/Stebalien/tempfile) | `3.10.1` | `3.12.0` | | [num_enum](https://github.com/illicitonion/num_enum) | `0.7.2` | `0.7.3` | | [bitflags](https://github.com/bitflags/bitflags) | `2.4.1` | `2.6.0` | | [serde](https://github.com/serde-rs/serde) | `1.0.204` | `1.0.206` | | [anstream](https://github.com/rust-cli/anstyle) | `0.6.14` | `0.6.15` | | [anstyle](https://github.com/rust-cli/anstyle) | `1.0.7` | `1.0.8` | | [anstyle-parse](https://github.com/rust-cli/anstyle) | `0.2.4` | `0.2.5` | | [anstyle-query](https://github.com/rust-cli/anstyle) | `1.1.0` | `1.1.1` | | [anstyle-wincon](https://github.com/rust-cli/anstyle) | `3.0.3` | `3.0.4` | | [cc](https://github.com/rust-lang/cc-rs) | `1.1.6` | `1.1.10` | | [clap_lex](https://github.com/clap-rs/clap) | `0.7.1` | `0.7.2` | | [colorchoice](https://github.com/rust-cli/anstyle) | `1.0.1` | `1.0.2` | | [env_filter](https://github.com/rust-cli/env_logger) | `0.1.0` | `0.1.2` | | [indexmap](https://github.com/indexmap-rs/indexmap) | `2.2.6` | `2.3.0` | | [is_terminal_polyfill](https://github.com/polyfill-rs/is_terminal_polyfill) | `1.70.0` | `1.70.1` | | [ppv-lite86](https://github.com/cryptocorrosion/cryptocorrosion) | `0.2.17` | `0.2.20` | | [regex](https://github.com/rust-lang/regex) | `1.10.5` | `1.10.6` | | [serde_spanned](https://github.com/toml-rs/toml) | `0.6.6` | `0.6.7` | | [target-lexicon](https://github.com/bytecodealliance/target-lexicon) | `0.12.15` | `0.12.16` | | [version_check](https://github.com/SergioBenitez/version_check) | `0.9.4` | `0.9.5` | Updates `clap` from 4.5.9 to 4.5.13 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.9...clap_complete-v4.5.13) Updates `env_logger` from 0.11.3 to 0.11.5 - [Release notes](https://github.com/rust-cli/env_logger/releases) - [Changelog](https://github.com/rust-cli/env_logger/blob/main/CHANGELOG.md) - [Commits](https://github.com/rust-cli/env_logger/compare/v0.11.3...v0.11.5) Updates `tempfile` from 3.10.1 to 3.12.0 - [Changelog](https://github.com/Stebalien/tempfile/blob/master/CHANGELOG.md) - [Commits](https://github.com/Stebalien/tempfile/commits) Updates `num_enum` from 0.7.2 to 0.7.3 - [Commits](https://github.com/illicitonion/num_enum/compare/0.7.2...0.7.3) Updates `bitflags` from 2.4.1 to 2.6.0 - [Release notes](https://github.com/bitflags/bitflags/releases) - [Changelog](https://github.com/bitflags/bitflags/blob/main/CHANGELOG.md) - [Commits](https://github.com/bitflags/bitflags/compare/2.4.1...2.6.0) Updates `serde` from 1.0.204 to 1.0.206 - [Release notes](https://github.com/serde-rs/serde/releases) - [Commits](https://github.com/serde-rs/serde/compare/v1.0.204...v1.0.206) Updates `anstream` from 0.6.14 to 0.6.15 - [Commits](https://github.com/rust-cli/anstyle/compare/anstream-v0.6.14...anstream-v0.6.15) Updates `anstyle` from 1.0.7 to 1.0.8 - [Commits](https://github.com/rust-cli/anstyle/compare/v1.0.7...v1.0.8) Updates `anstyle-parse` from 0.2.4 to 0.2.5 - [Commits](https://github.com/rust-cli/anstyle/compare/anstyle-parse-v0.2.4...anstyle-parse-v0.2.5) Updates `anstyle-query` from 1.1.0 to 1.1.1 - [Commits](https://github.com/rust-cli/anstyle/compare/anstyle-query-v1.1.0...anstyle-query-v1.1.1) Updates `anstyle-wincon` from 3.0.3 to 3.0.4 - [Commits](https://github.com/rust-cli/anstyle/compare/anstyle-wincon-v3.0.3...anstyle-wincon-v3.0.4) Updates `cc` from 1.1.6 to 1.1.10 - [Release notes](https://github.com/rust-lang/cc-rs/releases) - [Changelog](https://github.com/rust-lang/cc-rs/blob/main/CHANGELOG.md) - [Commits](https://github.com/rust-lang/cc-rs/compare/cc-v1.1.6...cc-v1.1.10) Updates `clap_builder` from 4.5.9 to 4.5.13 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/v4.5.9...v4.5.13) Updates `clap_derive` from 4.5.8 to 4.5.13 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/v4.5.8...v4.5.13) Updates `clap_lex` from 0.7.1 to 0.7.2 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/clap_lex-v0.7.1...clap_lex-v0.7.2) Updates `colorchoice` from 1.0.1 to 1.0.2 - [Commits](https://github.com/rust-cli/anstyle/compare/colorchoice-v1.0.1...colorchoice-v1.0.2) Updates `env_filter` from 0.1.0 to 0.1.2 - [Release notes](https://github.com/rust-cli/env_logger/releases) - [Changelog](https://github.com/rust-cli/env_logger/blob/main/CHANGELOG.md) - [Commits](https://github.com/rust-cli/env_logger/compare/env_filter-v0.1.0...env_filter-v0.1.2) Updates `indexmap` from 2.2.6 to 2.3.0 - [Changelog](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md) - [Commits](https://github.com/indexmap-rs/indexmap/compare/2.2.6...2.3.0) Updates `is_terminal_polyfill` from 1.70.0 to 1.70.1 - [Changelog](https://github.com/polyfill-rs/is_terminal_polyfill/blob/main-v1.70/CHANGELOG.md) - [Commits](https://github.com/polyfill-rs/is_terminal_polyfill/compare/v1.70.0...v1.70.1) Updates `num_enum_derive` from 0.7.2 to 0.7.3 - [Commits](https://github.com/illicitonion/num_enum/compare/0.7.2...0.7.3) Updates `ppv-lite86` from 0.2.17 to 0.2.20 - [Commits](https://github.com/cryptocorrosion/cryptocorrosion/commits) Updates `regex` from 1.10.5 to 1.10.6 - [Release notes](https://github.com/rust-lang/regex/releases) - [Changelog](https://github.com/rust-lang/regex/blob/master/CHANGELOG.md) - [Commits](https://github.com/rust-lang/regex/compare/1.10.5...1.10.6) Updates `serde_derive` from 1.0.204 to 1.0.206 - [Release notes](https://github.com/serde-rs/serde/releases) - [Commits](https://github.com/serde-rs/serde/compare/v1.0.204...v1.0.206) Updates `serde_spanned` from 0.6.6 to 0.6.7 - [Commits](https://github.com/toml-rs/toml/compare/serde_spanned-v0.6.6...serde_spanned-v0.6.7) Updates `target-lexicon` from 0.12.15 to 0.12.16 - [Commits](https://github.com/bytecodealliance/target-lexicon/compare/v0.12.15...v0.12.16) Updates `version_check` from 0.9.4 to 0.9.5 - [Commits](https://github.com/SergioBenitez/version_check/compare/v0.9.4...v0.9.5) --- updated-dependencies: - dependency-name: clap dependency-type: direct:production update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: env_logger dependency-type: direct:production update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: tempfile dependency-type: direct:production update-type: version-update:semver-minor dependency-group: vhost-device - dependency-name: num_enum dependency-type: direct:production update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: bitflags dependency-type: direct:production update-type: version-update:semver-minor dependency-group: vhost-device - dependency-name: serde dependency-type: direct:production update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: anstream dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: anstyle dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: anstyle-parse dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: anstyle-query dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: anstyle-wincon dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: cc dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: clap_builder dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: clap_derive dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: clap_lex dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: colorchoice dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: env_filter dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: indexmap dependency-type: indirect update-type: version-update:semver-minor dependency-group: vhost-device - dependency-name: is_terminal_polyfill dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: num_enum_derive dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: ppv-lite86 dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: regex dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: serde_derive dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: serde_spanned dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: target-lexicon dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device - dependency-name: version_check dependency-type: indirect update-type: version-update:semver-patch dependency-group: vhost-device ... Signed-off-by: dependabot[bot] <support@github.com> |
||
|---|---|---|
| .. | ||
| src | ||
| Cargo.toml | ||
| CHANGELOG.md | ||
| LICENSE-APACHE | ||
| LICENSE-BSD-3-Clause | ||
| README.md | ||
vhost-device-rng - RNG emulation backend daemon
Description
This program is a vhost-user backend that emulates a VirtIO random number generator (RNG). It uses the host's random number generator pool, /dev/urandom by default but configurable at will, to satisfy requests from guests.
The daemon is designed to respect limitation on possible random generator hardware using the --max-bytes and --period options. As such 5 kilobyte per second would translate to "--max-bytes 5000 --period 1000". If an application requests more bytes than the allowed limit the thread will block until the start of a new period. The daemon will automatically split the available bandwidth equally between the guest when several threads are requested.
Thought developed and tested with QEMU, the implemenation is based on the vhost-user protocol and as such should be interoperable with other virtual machine managers. Please see below for working examples.
Synopsis
vhost-device-rng [OPTIONS]
Options
.. program:: vhost-device-rng
.. option:: -h, --help
Print help.
.. option:: -s, --socket-path=PATH
Location of vhost-user Unix domain sockets, this path will be suffixed with 0,1,2..socket_count-1.
.. option:: -f, --filename Random number generator source file, defaults to /dev/urandom.
.. option:: -c, --socket-count=INT
Number of guests (sockets) to attach to, default set to 1.
.. option:: -p, --period
Rate, in milliseconds, at which the RNG hardware can generate random data. Used in conjunction with the --max-bytes option.
.. option:: -m, --max-bytes
In conjuction with the --period parameter, provides the maximum number of byte per milliseconds a RNG device can generate.
Examples
The daemon should be started first:
::
host# vhost-device-rng --socket-path=/some/path/rng.sock -c 1 -m 512 -p 1000
Note that from the above command the socket path "/some/path/rng.sock0" will be created. This in turn needs to be communicated as a chardev socket to QEMU in order for the backend RNG device to communicate with the vhost RNG daemon:
::
host# qemu-system -M virt
-object memory-backend-file,id=mem,size=4G,mem-path=/dev/shm,share=on
-chardev socket,path=/some/path/rng.sock0,id=rng0
-device vhost-user-rng-pci,chardev=rng0
-numa node,memdev=mem
...
License
This project is licensed under either of
- Apache License, Version 2.0
- BSD-3-Clause License