netfilter: nf_tables: missing error reporting for not selected expressions
stable inclusion from stable-5.10.43 commit 316de9a88c83c672c18d35bd76034d84e3769fe9 bugzilla: https://bugzilla.openeuler.org/show_bug.cgi?id=324 CVE: NA -------------------------------- commit c781471d upstream. Sometimes users forget to turn on nftables extensions from Kconfig that they need. In such case, the error reporting from userspace is misleading: $ sudo nft add rule x y counter Error: Could not process rule: No such file or directory add rule x y counter ^^^^^^^^^^^^^^^^^^^^ Add missing NL_SET_BAD_ATTR() to provide a hint: $ nft add rule x y counter Error: Could not process rule: No such file or directory add rule x y counter ^^^^^^^ Fixes: 83d9dcba ("netfilter: nf_tables: extended netlink error reporting for expressions") Signed-off-by: NPablo Neira Ayuso <pablo@netfilter.org> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by:fanxingin <fanxingin@qq.com> Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
Showing
想要评论请 注册 或 登录