linux/net/ieee802154
Ignat Korchagin b4fcd63f6e net: ieee802154: do not leave a dangling sk pointer in ieee802154_create()
sock_init_data() attaches the allocated sk object to the provided sock
object. If ieee802154_create() fails later, the allocated sk object is
freed, but the dangling pointer remains in the provided sock object, which
may allow use-after-free.

Clear the sk pointer in the sock object on error.

Signed-off-by: Ignat Korchagin <ignat@cloudflare.com>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Reviewed-by: Eric Dumazet <edumazet@google.com>
Link: https://patch.msgid.link/20241014153808.51894-6-ignat@cloudflare.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2024-10-15 18:43:08 -07:00
..
6lowpan netdev_features: convert NETIF_F_NETNS_LOCAL to dev->netns_local 2024-09-03 11:36:43 +02:00
core.c netdev_features: convert NETIF_F_NETNS_LOCAL to dev->netns_local 2024-09-03 11:36:43 +02:00
core.h
header_ops.c mac802154: Handle received BEACON_REQ 2023-03-23 21:51:30 +01:00
ieee802154.h
Kconfig
Makefile ieee802154: Internal PAN management 2023-11-20 11:41:06 +01:00
netlink.c genetlink: start to validate reserved header bytes 2022-08-29 12:47:15 +01:00
nl802154.c ieee802154: Avoid confusing changes after associating 2023-12-15 11:14:55 +01:00
nl802154.h ieee802154: Add support for user beaconing requests 2023-01-28 13:51:22 +01:00
nl_policy.c
nl-mac.c ieee802154: fix error return code in ieee802154_llsec_getparams() 2021-06-03 10:59:49 +02:00
nl-phy.c net: ieee802154: Use the IEEE802154_MAX_PAGE define when relevant 2022-01-28 11:23:30 +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 net: ieee802154: do not leave a dangling sk pointer in ieee802154_create() 2024-10-15 18:43:08 -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
trace.h tracing/treewide: Remove second parameter of __assign_str() 2024-05-22 20:14:47 -04:00