crosvm/vhost
Daniel Verkamp 0090567d24 vhost: improve set_vring_addr() validation
Use the GuestMemory get_slice_at_addr() function to ensure the memory
regions corresponding to the descriptor table and used/avail rings are
actually contiguous, rather than just validating the ending address of
each region exists in guest memory.

The log region is currently not validated, which matches previous
behavior.

BUG=None
TEST=tools/dev_container tools/presubmit

Change-Id: I1e80326dfae085380fbbf4dd1c7960dd72485793
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5922041
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Keiichi Watanabe <keiichiw@chromium.org>
2024-10-11 00:56:40 +00:00
..
src vhost: improve set_vring_addr() validation 2024-10-11 00:56:40 +00:00
tests Fix tests with non-4K pages 2023-11-10 23:26:00 +00:00
Cargo.toml Cargo.toml: avoid "*" versions for external crates 2024-05-22 01:01:42 +00:00