Last active
March 29, 2017 20:18
-
-
Save Laica-Lunasys/53a403251edb3d9f44fbe022fd0273f3 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Allow only CloudFlare | |
for cf in $(curl https://www.cloudflare.com/ips-v4); do | |
echo -e "-> Adding CloudFlare IPs: $cf" | |
iptables -A INPUT -p tcp -m multiport --dports 80,443 -s "$cf" -j ACCEPT | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment