e1000: switch to use qemu_receive_packet() for loopback
commit1caff0340f49c93d535c6558a5138d20d475315c
authorJason Wang <jasowang@redhat.com>
Wed, 24 Feb 2021 04:13:22 +0000 (24 12:13 +0800)
committerJason Wang <jasowang@redhat.com>
Mon, 15 Mar 2021 08:41:22 +0000 (15 16:41 +0800)
treec7bfab49856f2cb976c35e7f8faffd796bcdec1b
parent705df5466c98f3efdd2b68d3b31dad86858acad7
e1000: switch to use qemu_receive_packet() for loopback

This patch switches to use qemu_receive_packet() which can detect
reentrancy and return early.

This is intended to address CVE-2021-3416.

Cc: Prasad J Pandit <ppandit@redhat.com>
Cc: qemu-stable@nongnu.org
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
hw/net/e1000.c