Skip to content

Latest commit

 

History

History
43 lines (31 loc) · 1.12 KB

test-commands.md

File metadata and controls

43 lines (31 loc) · 1.12 KB
curl --resolve host1.website1.com:8006:127.0.0.1 http://host1.website1.com:8006
curl --resolve host2.website1.com:8006:127.0.0.1 http://host2.website1.com:8006
curl --resolve host2.website1.com:8006:127.0.0.1 http://host2.website1.com:8006/redirect/ -i
curl --resolve host1.website2.com:8007:127.0.0.1 http://host1.website2.com:8007

Testing clientMaxBodySize

curl -X POST -H "Content-Type: plain/text" --data "BODY IS HERE write something shorter or longer than body limit" --resolve host1.website1.com:8006:127.0.0.1 http://host1.website1.com:8006

Test chunked request with cgi script

echo -e "POST /cgi-bin/post_request_test.py HTTP/1.1\r\nHost:127.0.0.1: 8006\r\nTransfer-Encoding: chunked\r\n\r\n4\r\nWiki\r\n7\r\npedia i\r\n0\r\n\r\n" | nc 127.0.0.1 8006

Testing bad requests

echo -e "GET / HTTP/1.1\r\n\r\n" | nc 127.0.0.1 8006
echo -e "GET / HTTP/1.1\r\nHost: 127.0.0.1:8006\r\n\r\n" | nc 127.0.0.1 8006
echo -e "GET / HTTP/1.0\r\nHost: 127.0.0.1:8006\r\n\r\n" | nc 127.0.0.1 8006
http://127.0.0.1:8007/cgi-bin/html_test.py?file=html/index_cgi.html