]> git.ipfire.org Git - thirdparty/ipset.git/commit
add ipset to nftables translation infrastructure
authorPablo Neira Ayuso <pablo@netfilter.org>
Fri, 25 Jun 2021 20:30:42 +0000 (22:30 +0200)
committerJozsef Kadlecsik <kadlec@netfilter.org>
Sat, 26 Jun 2021 21:07:35 +0000 (23:07 +0200)
commit325af556cd3a6d1636c0cd355b494c87f58397e0
tree1c433f1f08d467074908e8edf132d2a940a66bef
parentff7f000ef2dbe81444a4e204dbab9a2177c35e21
add ipset to nftables translation infrastructure

This patch provides the ipset-translate utility which allows you to
translate your existing ipset file to nftables.

The ipset-translate utility is actually a symlink to ipset, which checks
for 'argv[0] == ipset-translate' to exercise the translation path.

You can translate your ipset file through:

ipset-translate restore < sets.ipt

This patch reuses the existing parser and API to represent the sets and
the elements.

There is a new ipset_xlate_set dummy object that allows to store a
created set to fetch the type without interactions with the kernel.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Jozsef Kadlecsik <kadlec@netfilter.org>
configure.ac
include/libipset/Makefile.am
include/libipset/xlate.h [new file with mode: 0644]
lib/ipset.c
src/Makefile.am
src/ipset-translate.8 [new file with mode: 0644]
src/ipset.c