Re: [PATCH net] net: openvswitch: fix nested key length validation in the set() action

From: Eelco Chaudron
Date: Mon Apr 14 2025 - 03:03:20 EST




On 12 Apr 2025, at 12:40, Ilya Maximets wrote:

> It's not safe to access nla_len(ovs_key) if the data is smaller than
> the netlink header. Check that the attribute is OK first.
>
> Fixes: ccb1352e76cf ("net: Add Open vSwitch kernel components.")
> Reported-by: syzbot+b07a9da40df1576b8048@xxxxxxxxxxxxxxxxxxxxxxxxx
> Closes: https://syzkaller.appspot.com/bug?extid=b07a9da40df1576b8048
> Tested-by: syzbot+b07a9da40df1576b8048@xxxxxxxxxxxxxxxxxxxxxxxxx
> Signed-off-by: Ilya Maximets <i.maximets@xxxxxxx>

The patch looks good to me.

Reviewed-by: Eelco Chaudron <echaudro@xxxxxxxxxx>