diff options
author | linzhecheng <linzhecheng@huawei.com> | 2018-03-28 21:34:35 +0800 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2018-04-09 16:36:39 +0200 |
commit | 9f91022f28dc092e3b3250823814e4b3191c51ed (patch) | |
tree | 6caed76477a613e83385178fba166a8ea26eb33f /scsi/qemu-pr-helper.c | |
parent | c2b01cfec1f1426d95c27abacc3ea5b5fbb9a57e (diff) |
virtio-serial: fix heapover-flow
Check device having the feature of VIRTIO_CONSOLE_F_EMERG_WRITE before
get config->emerg_wr. It is neccessary because sizeof(virtio_console_config)
is 8 byte if VirtIOSerial doesn't have the feature of
VIRTIO_CONSOLE_F_EMERG_WRITE(see virtio_serial_device_realize),
read/write emerg_wr will lead to heap-over-flow.
Signed-off-by: linzhecheng <linzhecheng@huawei.com>
Message-Id: <20180328133435.20112-1-linzhecheng@huawei.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'scsi/qemu-pr-helper.c')
0 files changed, 0 insertions, 0 deletions