linux/net/ieee802154
Zhiling Zou bf79662bc8 ieee802154: 6lowpan: fix NULL dereference in lowpan_newlink
TUNSETLINK allows a TUN device to change its link-layer type to
ARPHRD_IEEE802154 without initializing ieee802154_ptr. lowpan_newlink()
checks only the device type before dereferencing the pointer, so an
RTM_NEWLINK request can trigger a NULL pointer dereference.

Reject devices without ieee802154_ptr along with devices of the wrong type.

Fixes: 51e0e5d812 ("ieee802154: 6lowpan: remove multiple lowpan per wpan support")
Cc: stable@vger.kernel.org
Reported-by: Vega <vega@nebusec.ai>
Signed-off-by: Zhiling Zou <zhilinz@nebusec.ai>
Link: https://lore.kernel.org/0b715da69bd15a86ddc47dad5cf12da648211050.1787997209.git.zhilinz@nebusec.ai
Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
2026-09-02 09:54:27 +02:00
..
6lowpan ieee802154: 6lowpan: fix NULL dereference in lowpan_newlink 2026-09-02 09:54:27 +02:00
core.c ieee802154: Remove WARN_ON() in cfg802154_pernet_exit() 2026-06-19 21:40:53 +02:00
core.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
header_ops.c ieee802154: fix kernel-infoleak in dgram_recvmsg() 2026-06-19 22:49:48 +02:00
ieee802154.h ieee802154: allow legacy LLSEC ADD/DEL ops to pass strict validation 2026-06-19 23:02:42 +02:00
Kconfig treewide: replace '---help---' in Kconfig files with 'help' 2020-06-14 01:57:21 +09:00
Makefile ieee802154: Internal PAN management 2023-11-20 11:41:06 +01:00
netlink.c ieee802154: allow legacy LLSEC ADD/DEL ops to pass strict validation 2026-06-19 23:02:42 +02:00
nl_policy.c nl802154: add missing attribute validation for dev_type 2020-03-03 13:28:48 -08:00
nl-mac.c net: convert to nla_get_*_default() 2024-11-11 10:32:06 -08:00
nl-phy.c net: core: Convert dev_set_mac_address() to struct sockaddr_storage 2025-05-27 08:25:43 +02:00
nl802154.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
nl802154.h ieee802154: Add support for user beaconing requests 2023-01-28 13:51:22 +01:00
pan.c mac802154: Avoid new associations while disassociating 2023-12-15 11:14:57 +01:00
rdev-ops.h ieee802154: Add support for user disassociation requests 2023-11-20 11:42:47 +01:00
socket.c ieee802154: convert dgram getsockopt to sockopt_t 2026-08-03 16:55:23 -07:00
sysfs.c ieee802154: cfg802154: make wpan_phy_class constant 2024-03-06 21:23:10 +01:00
sysfs.h ieee802154: cfg802154: make wpan_phy_class constant 2024-03-06 21:23:10 +01:00
trace.c ieee802154: Add trace events for rdev->ops 2015-04-30 18:48:09 +02:00
trace.h tracing/treewide: Remove second parameter of __assign_str() 2024-05-22 20:14:47 -04:00