summaryrefslogtreecommitdiffstats
path: root/include/rule.h
diff options
context:
space:
mode:
authorJose M. Guisado Gomez <guigom@riseup.net>2020-08-21 18:40:30 +0200
committerPablo Neira Ayuso <pablo@netfilter.org>2020-08-28 19:48:20 +0200
commitc156232a530b30b6668712eda22bc491b0900283 (patch)
tree96a5bbe49f6eb483dca2d57f743c95a5129cc082 /include/rule.h
parentfbd8fb09c50bcee3f046dce2281f25baa4e14927 (diff)
src: add comment support when adding tables
Adds userdata building logic if a comment is specified when creating a new table. Adds netlink userdata parsing callback function. Relies on kernel supporting userdata for nft_table. Example: > nft add table ip x { comment "test"\; } > nft list ruleset table ip x { comment "test" } Signed-off-by: Jose M. Guisado Gomez <guigom@riseup.net> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include/rule.h')
-rw-r--r--include/rule.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/rule.h b/include/rule.h
index 62d25be2..56f1951f 100644
--- a/include/rule.h
+++ b/include/rule.h
@@ -162,6 +162,7 @@ struct table {
struct list_head chain_bindings;
enum table_flags flags;
unsigned int refcnt;
+ const char *comment;
};
extern struct table *table_alloc(void);