]> git.baikalelectronics.ru Git - kernel.git/commit
netfilter: nftables: netlink support for several set element expressions
authorPablo Neira Ayuso <pablo@netfilter.org>
Mon, 7 Dec 2020 16:37:14 +0000 (17:37 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Sat, 12 Dec 2020 18:20:52 +0000 (19:20 +0100)
commitd80bab9effe1c4257e818c523e0b8cd6fc757370
treeaca93688b8f9d6b909d8b6634f03d2e9b7ccb6e0
parent01bbfb8ae5fd3817aee03702d9e3ae8c6f5621b1
netfilter: nftables: netlink support for several set element expressions

This patch adds three new netlink attributes to encapsulate a list of
expressions per set elements:

- NFTA_SET_EXPRESSIONS: this attribute provides the set definition in
  terms of expressions. New set elements get attached the list of
  expressions that is specified by this new netlink attribute.
- NFTA_SET_ELEM_EXPRESSIONS: this attribute allows users to restore (or
  initialize) the stateful information of set elements when adding an
  element to the set.
- NFTA_DYNSET_EXPRESSIONS: this attribute specifies the list of
  expressions that the set element gets when it is inserted from the
  packet path.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
include/uapi/linux/netfilter/nf_tables.h
net/netfilter/nf_tables_api.c
net/netfilter/nft_dynset.c