]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
xtables-monitor: Support arptables chain events
authorPhil Sutter <phil@nwl.cc>
Fri, 12 Jul 2024 13:48:49 +0000 (15:48 +0200)
committerPhil Sutter <phil@nwl.cc>
Sat, 27 Jul 2024 12:32:39 +0000 (14:32 +0200)
Print arptables NEWCHAIN/DELCHAIN events just like for iptables, using
the '-0' prefix rule callback already uses.

Signed-off-by: Phil Sutter <phil@nwl.cc>
iptables/xtables-monitor.c

index e136e9b722e925518a469399e9bb09def7f73481..714a2dfd7074ada507f3da29ecebcc90884d43e3 100644 (file)
@@ -151,6 +151,9 @@ static int chain_cb(const struct nlmsghdr *nlh, void *data)
        case NFPROTO_IPV6:
                family = 6;
                break;
+       case NFPROTO_ARP:
+               family = 0;
+               break;
        default:
                nftnl_chain_snprintf(buf, sizeof(buf), c, NFTNL_OUTPUT_DEFAULT, 0);
                printf("nft: %s chain: %s\n",