diff options
author | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2024-11-01 13:39:17 +0000 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2024-11-04 16:03:25 -0500 |
commit | 721c99aefcdb311bd41d20678d3935fd11454641 (patch) | |
tree | 895c4bd0cb48f3fbaad3de8d927e8c8bf19d10d4 /hw/char/serial-pci.c | |
parent | 5300bdf5898dda5989215e183bccd555cc782b9a (diff) | |
download | qemu-721c99aefcdb311bd41d20678d3935fd11454641.zip qemu-721c99aefcdb311bd41d20678d3935fd11454641.tar.gz qemu-721c99aefcdb311bd41d20678d3935fd11454641.tar.bz2 |
hw/cxl: Ensure there is enough data to read the input header in cmd_get_physical_port_state()
If len_in is smaller than the header length then the accessing the
number of ports will result in an out of bounds access.
Add a check to avoid this.
Reported-by: Esifiel <esifiel@gmail.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Message-Id: <20241101133917.27634-11-Jonathan.Cameron@huawei.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/char/serial-pci.c')
0 files changed, 0 insertions, 0 deletions