History

netfilter: nf_tables: Expose the table usage counter via netlink

Userspace can therefore know whether a table is in use or not, and by how many chains. Suggested by Pablo Neira Ayuso.

Tomasz Bursztyka committed 12 years ago

Commit d8bcc761 parent 0aff0782 files · +4 −1Browse files

Showing the changes to include/uapi/linux (1 of 2 files). Show all

Unified · Split

include/uapi/linux/netfilter/nf_tables.h+2−0
@@ -110,11 +110,13 @@ enum nft_table_flags { · 109 unmodified lines
110110 *
111111 * @NFTA_TABLE_NAME: name of the table (NLA_STRING)
112112 * @NFTA_TABLE_FLAGS: bitmask of enum nft_table_flags (NLA_U32)
113+ * @NFTA_TABLE_USE: number of chains in this table (NLA_U32)
113114 */
114115 enum nft_table_attributes {
115116 NFTA_TABLE_UNSPEC,
116117 NFTA_TABLE_NAME,
117118 NFTA_TABLE_FLAGS,
119+ NFTA_TABLE_USE,
118120 __NFTA_TABLE_MAX
119121 };
120122 #define NFTA_TABLE_MAX (__NFTA_TABLE_MAX - 1)