linux-sg2042/include/linux/can
Oliver Hartkopp e7153bf70c can: can_dropped_invalid_skb(): ensure an initialized headroom in outgoing CAN sk_buffs
KMSAN sysbot detected a read access to an untinitialized value in the
headroom of an outgoing CAN related sk_buff. When using CAN sockets this
area is filled appropriately - but when using a packet socket this
initialization is missing.

The problematic read access occurs in the CAN receive path which can
only be triggered when the sk_buff is sent through a (virtual) CAN
interface. So we check in the sending path whether we need to perform
the missing initializations.

Fixes: d3b58c47d3 ("can: replace timestamp as unique skb attribute")
Reported-by: syzbot+b02ff0707a97e4e79ebb@syzkaller.appspotmail.com
Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
Tested-by: Oliver Hartkopp <socketcan@hartkopp.net>
Cc: linux-stable <stable@vger.kernel.org> # >= v4.1
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2020-01-02 15:34:27 +01:00
..
dev treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 285 2019-06-05 17:36:37 +02:00
platform can: mcp251x: get rid of legacy platform data 2019-11-11 21:57:28 +01:00
can-ml.h can: add support of SAE J1939 protocol 2019-09-04 14:22:33 +02:00
core.h can: af_can: export can_sock_destruct() 2019-11-13 10:42:33 +01:00
dev.h can: can_dropped_invalid_skb(): ensure an initialized headroom in outgoing CAN sk_buffs 2020-01-02 15:34:27 +01:00
led.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
rx-offload.h can: rx-offload: Prepare for CAN FD support 2019-11-11 21:58:10 +01:00
skb.h can: Add SPDX license identifiers for CAN subsystem 2019-07-24 10:31:55 +02:00