Last active
June 4, 2020 16:23
-
-
Save hakuno/c820364ec86619031867c9e907248023 to your computer and use it in GitHub Desktop.
Make sure iptables and conntrack don't interfere with our traffic
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
Example | |
client$ iptables -I INPUT 1 --src 192.168.254.0/24 -j ACCEPT | |
client$ iptables -t raw -I PREROUTING 1 --src 192.168.254.0/24 -j NOTRACK | |
server$ iptables -I INPUT 1 --src 192.168.254.0/24 -j ACCEPT | |
server$ iptables -t raw -I PREROUTING 1 --src 192.168.254.0/24 -j NOTRACK | |
Example | |
receiver$ iptables -I INPUT 1 -p udp --dport 4321 -j ACCEPT | |
receiver$ iptables -t raw -I PREROUTING 1 -p udp --dport 4321 -j NOTRACK | |
Example | |
iptables -t raw -I PREROUTING -d 198.18.0.12 -p udp -m udp --dport 1234 -j NOTRACK | |
Sources | |
https://blog.cloudflare.com/how-to-drop-10-million-packets/ | |
https://blog.cloudflare.com/how-to-achieve-low-latency/ | |
https://blog.cloudflare.com/how-to-receive-a-million-packets/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment