History

Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next

Pablo Neira Ayuso says: ==================== Netfilter/IPVS updates for net-next This small patchset contains three accumulated Netfilter/IPVS updates, they are: 1) Refactorize common NAT code by encapsulating it into a helper function, similarly to what we do in other conntrack extensions, from Florian Westphal. 2) A minor format string mismatch fix for IPVS, from Masanari Iida. 3) Add quota support to the netfilter accounting infrastructure, now you can add quotas to accounting objects via the nfnetlink interface and use them from iptables. You can also listen to quota notifications from userspace. This enhancement from Mathieu Poirier. ====================

David S. Miller committed 12 years ago

Commit 90d0e082 parents 648d4fe f768e5b12 files · +138 −51Browse files

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

Unified · Split

2 files
  1. include/uapi/linux/netfilter/nfnetlink.h +2 −0
  2. include/uapi/linux/netfilter/nfnetlink_acct.h +9 −0
include/uapi/linux/netfilter/nfnetlink.h+2−0
@@ -20,6 +20,8 @@ enum nfnetlink_groups { · 19 unmodified lines
2020 #define NFNLGRP_CONNTRACK_EXP_DESTROY NFNLGRP_CONNTRACK_EXP_DESTROY
2121 NFNLGRP_NFTABLES,
2222 #define NFNLGRP_NFTABLES NFNLGRP_NFTABLES
23+ NFNLGRP_ACCT_QUOTA,
24+#define NFNLGRP_ACCT_QUOTA NFNLGRP_ACCT_QUOTA
2325 __NFNLGRP_MAX,
2426 };
2527 #define NFNLGRP_MAX (__NFNLGRP_MAX - 1)
include/uapi/linux/netfilter/nfnetlink_acct.h+9−0
@@ -10,15 +10,24 @@ enum nfnl_acct_msg_types { · 9 unmodified lines
1010 NFNL_MSG_ACCT_GET,
1111 NFNL_MSG_ACCT_GET_CTRZERO,
1212 NFNL_MSG_ACCT_DEL,
13+ NFNL_MSG_ACCT_OVERQUOTA,
1314 NFNL_MSG_ACCT_MAX
1415 };
1516
17+enum nfnl_acct_flags {
18+ NFACCT_F_QUOTA_PKTS = (1 << 0),
19+ NFACCT_F_QUOTA_BYTES = (1 << 1),
20+ NFACCT_F_OVERQUOTA = (1 << 2), /* can't be set from userspace */
21+};
22+
1623 enum nfnl_acct_type {
1724 NFACCT_UNSPEC,
1825 NFACCT_NAME,
1926 NFACCT_PKTS,
2027 NFACCT_BYTES,
2128 NFACCT_USE,
29+ NFACCT_FLAGS,
30+ NFACCT_QUOTA,
2231 __NFACCT_MAX
2332 };
2433 #define NFACCT_MAX (__NFACCT_MAX - 1)