mirror of https://github.com/nealey/eris.git
Parsing request OK
This commit is contained in:
parent
669fcc25a4
commit
3277e847a9
3
Makefile
3
Makefile
|
@ -1,6 +1,7 @@
|
||||||
VERSION := $(shell head -n 1 CHANGES | tr -d :)
|
VERSION := $(shell head -n 1 CHANGES | tr -d :)
|
||||||
|
|
||||||
CFLAGS = -DFNORD='"eris/$(VERSION)"' -Wall -Werror
|
CFLAGS = -DFNORD='"eris/$(VERSION)"' -Wall
|
||||||
|
#-Werror
|
||||||
|
|
||||||
all: eris
|
all: eris
|
||||||
|
|
||||||
|
|
6
test.sh
6
test.sh
|
@ -62,6 +62,9 @@ printf 'GET / HTTP/1.0\r\n\r\n' | $HTTPD 2>/dev/null | d | grep -q 'HTTP/1.0 200
|
||||||
title "POST"
|
title "POST"
|
||||||
printf 'POST / HTTP/1.0\r\nContent-Type: a\r\nContent-Length: 5\r\n\r\njames' | $HTTPD 2>/dev/null | d | grep -q 'HTTP/1.0 200 OK#%Server: [a-z]*/[0-9.]*#%Content-Type: text/html; charset=UTF-8#%Content-Length: 6#%Last-Modified: ..., .. ... 20.. ..:..:.. GMT#%#%james%' && pass || fail
|
printf 'POST / HTTP/1.0\r\nContent-Type: a\r\nContent-Length: 5\r\n\r\njames' | $HTTPD 2>/dev/null | d | grep -q 'HTTP/1.0 200 OK#%Server: [a-z]*/[0-9.]*#%Content-Type: text/html; charset=UTF-8#%Content-Length: 6#%Last-Modified: ..., .. ... 20.. ..:..:.. GMT#%#%james%' && pass || fail
|
||||||
|
|
||||||
|
title "HTTP/1.12"
|
||||||
|
printf 'GET / HTTP/1.12\r\n\r\n' | $HTTPD 2>/dev/null | grep -q 'HTTP/1.0 505' && pass || fail
|
||||||
|
|
||||||
title "Bare newline"
|
title "Bare newline"
|
||||||
printf 'GET / HTTP/1.0\n\n' | $HTTPD 2>/dev/null | d | grep -q 'HTTP/1.0 200 OK#%Server: [a-z]*/[0-9.]*#%Content-Type: text/html; charset=UTF-8#%Content-Length: 6#%Last-Modified: ..., .. ... 20.. ..:..:.. GMT#%#%james%' && pass || fail
|
printf 'GET / HTTP/1.0\n\n' | $HTTPD 2>/dev/null | d | grep -q 'HTTP/1.0 200 OK#%Server: [a-z]*/[0-9.]*#%Content-Type: text/html; charset=UTF-8#%Content-Length: 6#%Last-Modified: ..., .. ... 20.. ..:..:.. GMT#%#%james%' && pass || fail
|
||||||
|
|
||||||
|
@ -112,6 +115,9 @@ printf 'GET /a.cgi?foo HTTP/1.0\r\n\r\n' | $HTTPD_CGI 2>/dev/null | d | grep -q
|
||||||
title "POST"
|
title "POST"
|
||||||
printf 'POST /a.cgi HTTP/1.0\r\nContent-Type: moo\r\nContent-Length: 3\r\n\r\narf' | $HTTPD_CGI 2>/dev/null | d | grep -q 't:moo%v:arf$' && pass || fail
|
printf 'POST /a.cgi HTTP/1.0\r\nContent-Type: moo\r\nContent-Length: 3\r\n\r\narf' | $HTTPD_CGI 2>/dev/null | d | grep -q 't:moo%v:arf$' && pass || fail
|
||||||
|
|
||||||
|
title "PATH_INFO"
|
||||||
|
printf 'GET /a.cgi/merf HTTP/1.0\r\n\r\n' | $HTTPD_CGI 2>/dev/null | grep -q '200' && pass || fail
|
||||||
|
|
||||||
|
|
||||||
H "fnord bugs"
|
H "fnord bugs"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue