Created
October 17, 2012 17:22
-
-
Save jpetazzo/3906848 to your computer and use it in GitHub Desktop.
Simulate breaking of HTTP connection
This file contains 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
# You can adapt this; notably, I suggest that you: | |
# - change the port to your liking | |
# - maybe add a destination IP address to break more selectively | |
# - change the "4:" value (it says after how many packets the connection should break) | |
iptables -A OUTPUT -j REJECT --reject-with tcp-reset \ | |
-p tcp --dport 443 \ | |
-m connbytes --connbytes-dir both --connbytes-mode packets --connbytes 4: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment