All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH nf-next 0/2] netfilter: nf_tables: use NLA_POLICY_MASK instead of manual checks
@ 2023-07-18  7:52 Florian Westphal
  2023-07-18  7:52 ` [PATCH nf-next 1/2] netlink: allow be16 and be32 types in all uint policy checks Florian Westphal
  2023-07-18  7:52 ` [PATCH nf-next 2/2] netfilter: nf_tables: use NLA_POLICY_MASK to test for valid flag options Florian Westphal
  0 siblings, 2 replies; 7+ messages in thread
From: Florian Westphal @ 2023-07-18  7:52 UTC (permalink / raw)
  To: netfilter-devel
  Cc: Pablo Neira Ayuso, Jakub Kicinski, Paolo Abeni, Eric Dumazet,
	David S. Miller, netdev, Florian Westphal

nf_tables still uses manual attribute validation in multiple places.
Make NLA_POLICY_MASK available with NLA_BE16/NLA_BE32 and then start
using it for flag attribute validation.

Florian Westphal (2):
  netlink: allow be16 and be32 types in all uint policy checks
  netfilter: nf_tables: use NLA_POLICY_MASK to test for valid flag
    options

 include/net/netlink.h      | 10 +++-------
 lib/nlattr.c               |  6 ++++++
 net/netfilter/nft_fib.c    | 13 +++++++------
 net/netfilter/nft_lookup.c |  6 ++----
 net/netfilter/nft_masq.c   |  8 +++-----
 net/netfilter/nft_nat.c    |  8 +++-----
 net/netfilter/nft_redir.c  |  8 +++-----
 7 files changed, 27 insertions(+), 32 deletions(-)

-- 
2.41.0


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2023-07-19  7:19 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-18  7:52 [PATCH nf-next 0/2] netfilter: nf_tables: use NLA_POLICY_MASK instead of manual checks Florian Westphal
2023-07-18  7:52 ` [PATCH nf-next 1/2] netlink: allow be16 and be32 types in all uint policy checks Florian Westphal
2023-07-18 18:56   ` Jakub Kicinski
2023-07-19  2:53     ` Florian Westphal
2023-07-19  3:13       ` Jakub Kicinski
2023-07-19  7:19       ` Jozsef Kadlecsik
2023-07-18  7:52 ` [PATCH nf-next 2/2] netfilter: nf_tables: use NLA_POLICY_MASK to test for valid flag options Florian Westphal

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.