Commit 575ecefd authored by David Johnson's avatar David Johnson

Add pre/post-routing hooknums.

parent c7ebbbba
......@@ -72,9 +72,11 @@ class NFTables(NFTSocket):
commands = {'add': NFT_MSG_NEWCHAIN,
'del': NFT_MSG_DELCHAIN}
# TODO: cover all 6 hooks
hooks = {'input': 1,
hooks = {'prerouting': 0,
'input': 1,
'forward': 2,
'output': 3}
'output': 3,
'postrouting': 4}
if 'hook' in kwarg:
kwarg['hook'] = {'attrs':
[['NFTA_HOOK_HOOKNUM', hooks[kwarg['hook']]],
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment