https://github.com/torvalds/linux
Revision d8316f3991d207fe32881a9ac20241be8fa2bad0 authored by Michael S. Tsirkin on 27 March 2014, 10:00:26 UTC, committed by David S. Miller on 28 March 2014, 20:07:31 UTC
When mergeable buffers are disabled, and the
incoming packet is too large for the rx buffer,
get_rx_bufs returns success.

This was intentional in order for make recvmsg
truncate the packet and then handle_rx would
detect err != sock_len and drop it.

Unfortunately we pass the original sock_len to
recvmsg - which means we use parts of iov not fully
validated.

Fix this up by detecting this overrun and doing packet drop
immediately.

CVE-2014-0077

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 05efa8c
History
Tip revision: d8316f3991d207fe32881a9ac20241be8fa2bad0 authored by Michael S. Tsirkin on 27 March 2014, 10:00:26 UTC
vhost: fix total length when packets are too short
Tip revision: d8316f3
File Mode Size
Documentation
arch
block
crypto
drivers
firmware
fs
include
init
ipc
kernel
lib
mm
net
samples
scripts
security
sound
tools
usr
virt
.gitignore -rw-r--r-- 1.1 KB
.mailmap -rw-r--r-- 4.4 KB
COPYING -rw-r--r-- 18.3 KB
CREDITS -rw-r--r-- 93.3 KB
Kbuild -rw-r--r-- 2.5 KB
Kconfig -rw-r--r-- 252 bytes
MAINTAINERS -rw-r--r-- 267.3 KB
Makefile -rw-r--r-- 49.1 KB
README -rw-r--r-- 18.3 KB
REPORTING-BUGS -rw-r--r-- 7.3 KB

README

back to top