android_kernel_motorola_sm6225/net/ieee802154
Haimin Zhang 65d7f77be7 net/ieee802154: fix uninit value bug in dgram_sendmsg
[ Upstream commit 94160108a70c8af17fa1484a37e05181c0e094af ]

There is uninit value bug in dgram_sendmsg function in
net/ieee802154/socket.c when the length of valid data pointed by the
msg->msg_name isn't verified.

We introducing a helper function ieee802154_sockaddr_check_size to
check namelen. First we check there is addr_type in ieee802154_addr_sa.
Then, we check namelen according to addr_type.

Also fixed in raw_bind, dgram_bind, dgram_connect.

Signed-off-by: Haimin Zhang <tcs_kernel@tencent.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-10-26 13:19:17 +02:00
..
6lowpan inet: frags: call inet_frags_fini() after unregister_pernet_subsys() 2020-01-27 14:50:51 +01:00
core.c net: remove blank lines at end of file 2018-07-24 14:10:43 -07: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: change needed headroom/tailroom 2015-09-22 11:51:20 +02:00
ieee802154.h
Kconfig nl802154: add support for security layer 2015-09-30 13:16:44 +02:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
netlink.c ieee802154: netlink: fix typo of the name of struct genl_ops 2017-10-16 22:11:20 +02:00
nl-mac.c ieee802154: fix error return code in ieee802154_llsec_getparams() 2021-06-10 13:24:05 +02:00
nl-phy.c ieee802154: fix error return code in ieee802154_add_iface() 2021-06-10 13:24:05 +02:00
nl802154.c net: ieee802154: Return meaningful error codes from the netlink helpers 2022-02-08 18:23:16 +01:00
nl802154.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
nl_policy.c nl802154: add missing attribute validation for dev_type 2020-03-18 07:14:15 +01:00
rdev-ops.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
socket.c net/ieee802154: fix uninit value bug in dgram_sendmsg 2022-10-26 13:19:17 +02:00
sysfs.c
sysfs.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
trace.c
trace.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00