Add test cases for a crash reported by Bertrand PROVOST. When a
authorbluhm <bluhm@openbsd.org>
Sun, 17 May 2015 22:49:03 +0000 (22:49 +0000)
committerbluhm <bluhm@openbsd.org>
Sun, 17 May 2015 22:49:03 +0000 (22:49 +0000)
commit1b3c3ba0b914ab28a35c0ee0a65472bef46451e1
treef8620e8e43da4f9c910923dfedef99cec918e51a
parent4e18f26dcd1f552d5bb621113cfb229d4d789e9a
Add test cases for a crash reported by Bertrand PROVOST.  When a
HTTP client writes multiple requests or chunks in a single transfer,
relayd invokes the libevent callback manually for the next data.
If the callback closes the session, this results in an use after
free.
Test an invalid second request method, test an invalid header line
in the second PUT request, test an invalid second chunked length
for a PUT request.  Also test multiple valid HTTP 1.1 PUT requests
with chunked body.
To detect crashes of relayd, start it with "prefork 1" and grep for
"lost child" log messages.  Unfortunately only the first child is
monitored by the parent.
regress/usr.sbin/relayd/LICENSE
regress/usr.sbin/relayd/Relayd.pm
regress/usr.sbin/relayd/args-http-callback.pl [new file with mode: 0644]
regress/usr.sbin/relayd/args-http-chunked-callback.pl [new file with mode: 0644]
regress/usr.sbin/relayd/args-http-chunked-put.pl [new file with mode: 0644]
regress/usr.sbin/relayd/args-http-headline-callback.pl [new file with mode: 0644]
regress/usr.sbin/relayd/args-https-callback.pl [new file with mode: 0644]
regress/usr.sbin/relayd/args-https-chunked-callback.pl [new file with mode: 0644]
regress/usr.sbin/relayd/args-https-chunked-put.pl [new file with mode: 0644]
regress/usr.sbin/relayd/args-https-headline-callback.pl [new file with mode: 0644]
regress/usr.sbin/relayd/funcs.pl