Skip to content

Instantly share code, notes, and snippets.

@ArtemGr
Last active April 10, 2023 18:59
Show Gist options
  • Star 6 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save ArtemGr/5490781 to your computer and use it in GitHub Desktop.
Save ArtemGr/5490781 to your computer and use it in GitHub Desktop.
Testing HTTP pipelining from the command line.
# http://aaronhawley.livejournal.com/12621.html
(echo -en "GET / HTTP/1.1\nHost: fropl.com\n\nGET / HTTP/1.1\nHost: fropl.com\n\n"; sleep 0.1) | telnet localhost 80
# Also:
perl -e '$| = 1; print "GET / HTTP/1.1\nHost: fropl.com\n\nGET / HTTP/1.1\nHost: fropl.com\n\n"; sleep (1)' | telnet localhost 80
# Also (from https://github.com/ellzey/libevhtp/issues/86#issuecomment-19137572):
(echo -en "GET /1 HTTP/1.1\r\n\r\nGET /2 HTTP/1.1\r\n\r\n"; sleep 0.1) | nc localhost 8081
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment