net: mctp: ensure our nlmsg responses are initialised
authorJeremy Kerr <jk@codeconstruct.com.au>
Mon, 9 Feb 2026 07:27:33 +0000 (15:27 +0800)
committerJakub Kicinski <kuba@kernel.org>
Fri, 13 Feb 2026 02:35:45 +0000 (18:35 -0800)
commita6a9bc544b675d8b5180f2718ec985ad267b5cbf
treed6525a865db833f38db5cd5d7046d3c4a72cfb07
parent7c375811b5117dd26e36fc508cff1fb5cd4121aa
net: mctp: ensure our nlmsg responses are initialised

Syed Faraz Abrar (@farazsth98) from Zellic, and Pumpkin (@u1f383) from
DEVCORE Research Team working with Trend Micro Zero Day Initiative
report that a RTM_GETNEIGH will return uninitalised data in the pad
bytes of the ndmsg data.

Ensure we're initialising the netlink data to zero, in the link, addr
and neigh response messages.

Fixes: 831119f88781 ("mctp: Add neighbour netlink interface")
Fixes: 06d2f4c583a7 ("mctp: Add netlink route management")
Fixes: 583be982d934 ("mctp: Add device handling and netlink interface")
Signed-off-by: Jeremy Kerr <jk@codeconstruct.com.au>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://patch.msgid.link/20260209-dev-mctp-nlmsg-v1-1-f1e30c346a43@codeconstruct.com.au
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/mctp/device.c
net/mctp/neigh.c
net/mctp/route.c