libnftables way of deleting a rule
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- Subject: libnftables way of deleting a rule
- From: Arne Zachlod <arne@xxxxxxxxxxxxxx>
- Date: Wed, 31 Jul 2024 14:41:00 +0200
- User-agent: Mozilla Thunderbird
Hi,
I'm porting a program (written in C) that currently uses iptables to
nftables, trying to not change a lot of the internal concept of said
program.
The program currently uses execute() calls and calls iptables directly
via these. I wanted to at least use libnftables, and everything seems to
works quite well, I just have a problem with deleting rules.
I read through the code of libnftables, but I couldn't find a way to get
the handle of a rule I added. In iptables, this is no problem, you just
give the rule again to delete it. In libnftables though I need the
handle. Currently, I'm looking into libnftables-json, but I would prefer
not to use it just to get the handles. Is there a better way of deleting
a rule than parsing the JSON for them? Maybe even with libnftables directly?
Best Regards,
Arne
[Index of Archives]
[Linux Netfilter Development]
[Linux Kernel Networking Development]
[Netem]
[Berkeley Packet Filter]
[Linux Kernel Development]
[Advanced Routing & Traffice Control]
[Bugtraq]