Skip to content

Instantly share code, notes, and snippets.

@murka
Last active January 23, 2023 11:24
Show Gist options
  • Save murka/c99932fd1b2b1df20a763716442d3764 to your computer and use it in GitHub Desktop.
Save murka/c99932fd1b2b1df20a763716442d3764 to your computer and use it in GitHub Desktop.
Block all Hetzner sub network
iptables -I INPUT -p tcp -s 95.217.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 95.216.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 94.130.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 91.107.128.0/17 -j DROP
iptables -I INPUT -p tcp -s 88.99.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 88.198.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 85.10.192.0/18 -j DROP
iptables -I INPUT -p tcp -s 78.46.0.0/15 -j DROP
iptables -I INPUT -p tcp -s 65.21.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 65.109.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 65.108.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 5.9.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 5.75.128.0/17 -j DROP
iptables -I INPUT -p tcp -s 5.161.75.0/24 -j DROP
iptables -I INPUT -p tcp -s 5.161.72.0/24 -j DROP
iptables -I INPUT -p tcp -s 5.161.70.0/24 -j DROP
iptables -I INPUT -p tcp -s 5.161.65.0/24 -j DROP
iptables -I INPUT -p tcp -s 5.161.64.0/24 -j DROP
iptables -I INPUT -p tcp -s 5.161.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 46.4.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 195.201.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 193.47.99.0/24 -j DROP
iptables -I INPUT -p tcp -s 188.40.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 188.34.128.0/17 -j DROP
iptables -I INPUT -p tcp -s 185.50.120.0/23 -j DROP
iptables -I INPUT -p tcp -s 185.12.65.0/24 -j DROP
iptables -I INPUT -p tcp -s 178.63.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 176.9.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 168.119.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 167.235.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 167.233.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 162.55.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 159.69.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 157.90.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 148.251.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 144.76.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 142.132.128.0/17 -j DROP
iptables -I INPUT -p tcp -s 138.201.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 136.243.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 135.181.0.0/16 -j DROP
iptables -I INPUT -p tcp -s 128.140.0.0/17 -j DROP
iptables -I INPUT -p tcp -s 23.88.0.0/17 -j DROP
iptables -I INPUT -p tcp -s 213.239.192.0/18 -j DROP
iptables -I INPUT -p tcp -s 213.133.96.0/19 -j DROP
ip6tables -I INPUT -p tcp -s 2a01:4ff:ff01::/48 -j DROP
ip6tables -I INPUT -p tcp -s 2a01:4ff::/40 -j DROP
ip6tables -I INPUT -p tcp -s 2a01:4f9::/32 -j DROP
ip6tables -I INPUT -p tcp -s 2a01:4f8::/32 -j DROP
ip6tables -I INPUT -p tcp -s 2001:67c:192c::/48 -j DROP
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment