linux/net/batman-adv
Stanislav Fort d77b6ff0ce batman-adv: fix OOB read/write in network-coding decode
batadv_nc_skb_decode_packet() trusts coded_len and checks only against
skb->len. XOR starts at sizeof(struct batadv_unicast_packet), reducing
payload headroom, and the source skb length is not verified, allowing an
out-of-bounds read and a small out-of-bounds write.

Validate that coded_len fits within the payload area of both destination
and source sk_buffs before XORing.

Fixes: 2df5278b02 ("batman-adv: network coding - receive coded packets and decode them")
Cc: stable@vger.kernel.org
Reported-by: Stanislav Fort <disclosure@aisle.com>
Signed-off-by: Stanislav Fort <stanislav.fort@aisle.com>
Signed-off-by: Sven Eckelmann <sven@narfation.org>
Signed-off-by: Simon Wunderlich <sw@simonwunderlich.de>
2025-08-31 17:01:35 +02:00
..
Kconfig
Makefile
bat_algo.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
bat_algo.h batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
bat_iv_ogm.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
bat_iv_ogm.h
bat_v.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
bat_v.h
bat_v_elp.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
bat_v_elp.h
bat_v_ogm.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
bat_v_ogm.h
bitarray.c
bitarray.h
bridge_loop_avoidance.c
bridge_loop_avoidance.h
distributed-arp-table.c
distributed-arp-table.h
fragmentation.c
fragmentation.h
gateway_client.c
gateway_client.h
gateway_common.c
gateway_common.h
hard-interface.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
hard-interface.h
hash.c
hash.h
log.c
log.h
main.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
main.h batman-adv: Start new development cycle 2025-05-31 10:37:44 +02:00
mesh-interface.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
mesh-interface.h
multicast.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
multicast.h
multicast_forw.c
netlink.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
netlink.h
network-coding.c batman-adv: fix OOB read/write in network-coding decode 2025-08-31 17:01:35 +02:00
network-coding.h
originator.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
originator.h
routing.c
routing.h
send.c batman-adv: store hard_iface as iflink private data 2025-05-31 10:41:11 +02:00
send.h
tp_meter.c treewide, timers: Rename from_timer() to timer_container_of() 2025-06-08 09:07:37 +02:00
tp_meter.h
trace.c
trace.h
translation-table.c batman-adv: Switch to crc32 header for crc32c 2025-04-13 11:11:31 +02:00
translation-table.h
tvlv.c
tvlv.h
types.h