Re: [Qemu-devel] [PATCH V2] virtio: properly validate address before accessing config

2013-05-13 Thread Anthony Liguori
Applied. Thanks. Regards, Anthony Liguori

Re: [Qemu-devel] [PATCH V2] virtio: properly validate address before accessing config

2013-05-07 Thread Petr Matousek
On Tue, May 07, 2013 at 01:42:49PM +0800, Jason Wang wrote: > There are several several issues in the current checking: > > - The check was based on the minus of unsigned values which can overflow > - It was done after .{set|get}_config() which can lead crash when config_len > is zero since vdev

Re: [Qemu-devel] [PATCH V2] virtio: properly validate address before accessing config

2013-05-07 Thread Michael S. Tsirkin
On Tue, May 07, 2013 at 01:42:49PM +0800, Jason Wang wrote: > There are several several issues in the current checking: > > - The check was based on the minus of unsigned values which can overflow > - It was done after .{set|get}_config() which can lead crash when config_len > is zero since vdev

[Qemu-devel] [PATCH V2] virtio: properly validate address before accessing config

2013-05-06 Thread Jason Wang
There are several several issues in the current checking: - The check was based on the minus of unsigned values which can overflow - It was done after .{set|get}_config() which can lead crash when config_len is zero since vdev->config is NULL Fix this by: - Validate the address in virtio_pci_c