#!/bin/sh # 2024-04-16 02:39:49 TO IPTABLES=/usr/sbin/iptables IPSET=/usr/sbin/ipset $IPSET create BLOCKLIST hash:net $IPSET add BLOCKLIST 43.255.148.0/22 $IPSET add BLOCKLIST 103.124.187.0/24 $IPSET add BLOCKLIST 103.134.118.0/23 $IPSET add BLOCKLIST 103.239.160.0/22 $IPSET add BLOCKLIST 103.242.126.0/23 $IPSET add BLOCKLIST 103.245.160.0/22 $IPSET add BLOCKLIST 175.176.144.0/21 $IPSET add BLOCKLIST 202.43.8.0/21 $IPSET add BLOCKLIST 202.134.24.0/21 $IPTABLES -A INPUT -m set --match-set BLOCKLIST src -j DROP $IPTABLES -A OUTPUT -m set --match-set BLOCKLIST dst -j DROP