3 ms·
Just for people stumbling across this in the future: the general answer to blocking large numbers of discontiguous ranges of source IPs (or doing anything with
by tptacek 2y ago
Just for people stumbling across this in the future: the general answer to blocking large numbers of discontiguous ranges of source IPs (or doing anything with those kinds of ranges) is `ipset`, which has iirc a hash and radix trie backend in the kernel.
If you wanted to be super awesome about it, you could write a 20 line eBPF XDP program to do the same thing, populating hash and LPM trie maps of addresses and dropping crawlers without so much as giving them an skbuff for their SYN packets. But `ipset` is fine.