Skip to content
Snippets Groups Projects
Commit f8d6f3b1 authored by Cédric Le Goater's avatar Cédric Le Goater
Browse files

vfio/pci: Fix buffer overrun when writing the VF token


qemu_uuid_unparse() includes a trailing NUL when writing the uuid
string and the buffer size should be UUID_FMT_LEN + 1 bytes. Use the
recently added UUID_STR_LEN which defines the correct size.

Fixes: CID 1522913
Fixes: 2dca1b37 ("vfio/pci: add support for VF token")
Cc: Alex Williamson <alex.williamson@redhat.com>
Reviewed-by: default avatarAlex Williamson <alex.williamson@redhat.com>
Reviewed-by: default avatarJuan Quintela <quintela@redhat.com>
Reviewed-by: default avatar"Denis V. Lunev" <den@openvz.org>
Signed-off-by: default avatarCédric Le Goater <clg@redhat.com>
parent 721da039
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment