tpws: ipset support

This commit is contained in:
bol-van
2024-10-14 14:58:31 +03:00
parent e23f61ed7d
commit 05978d9b35
12 changed files with 710 additions and 65 deletions

11
tpws/ipset.h Normal file
View File

@@ -0,0 +1,11 @@
#pragma once
#include <stdbool.h>
#include <arpa/inet.h>
#include "params.h"
#include "pools.h"
bool LoadIncludeIpsets();
bool LoadExcludeIpsets();
bool SearchIpset(const ipset *ips, const struct in_addr *ipv4, const struct in6_addr *ipv6);
bool IpsetCheck(struct desync_profile *dp, const struct in_addr *ipv4, const struct in6_addr *ipv6);