diff options
author | Stefan Eissing <icing@apache.org> | 2022-04-07 10:55:09 +0000 |
---|---|---|
committer | Stefan Eissing <icing@apache.org> | 2022-04-07 10:55:09 +0000 |
commit | 8ce99f9ef1f08bf4e9c209002ae92b9f08c307f5 (patch) | |
tree | bf85a7d03678cada347f2129ac73761954f12ceb /test/modules | |
parent | 0296d7dfeaf1d354b4df7c0c36fc690b8c51c4b4 (diff) | |
download | httpd-8ce99f9ef1f08bf4e9c209002ae92b9f08c307f5.tar.gz |
*) mod_http2: use the new RESPONSE buckets introduced in r1899648.
This replaces the internal H2_HEADERS bucket, removing its
source file and also obsoletes any interim response parsing
needs.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1899649 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'test/modules')
-rw-r--r-- | test/modules/http2/test_200_header_invalid.py | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/test/modules/http2/test_200_header_invalid.py b/test/modules/http2/test_200_header_invalid.py index b09a5a6ecb..5f8c976808 100644 --- a/test/modules/http2/test_200_header_invalid.py +++ b/test/modules/http2/test_200_header_invalid.py @@ -12,24 +12,22 @@ class TestInvalidHeaders: assert env.apache_restart() == 0 # let the hecho.py CGI echo chars < 0x20 in field name - # for almost all such characters, the stream gets aborted with a h2 error and - # there will be no http status, cr and lf are handled special + # for almost all such characters, the stream returns a 500 + # cr is handled special def test_h2_200_01(self, env): url = env.mkurl("https", "cgi", "/hecho.py") for x in range(1, 32): r = env.curl_post_data(url, "name=x%%%02xx&value=yz" % x) - if x in [10]: - assert 0 == r.exit_code, "unexpected exit code for char 0x%02x" % x - assert 500 == r.response["status"], "unexpected status for char 0x%02x" % x - elif x in [13]: + if x in [13]: assert 0 == r.exit_code, "unexpected exit code for char 0x%02x" % x assert 200 == r.response["status"], "unexpected status for char 0x%02x" % x else: - assert 0 != r.exit_code, "unexpected exit code for char 0x%02x" % x + assert 0 == r.exit_code, "unexpected exit code for char 0x%02x" % x + assert 500 == r.response["status"], "unexpected status for char 0x%02x" % x # let the hecho.py CGI echo chars < 0x20 in field value - # for almost all such characters, the stream gets aborted with a h2 error and - # there will be no http status, cr and lf are handled special + # for almost all such characters, the stream returns a 500 + # cr and lf are handled special def test_h2_200_02(self, env): url = env.mkurl("https", "cgi", "/hecho.py") for x in range(1, 32): @@ -39,17 +37,20 @@ class TestInvalidHeaders: assert 0 == r.exit_code, "unexpected exit code for char 0x%02x" % x assert 200 == r.response["status"], "unexpected status for char 0x%02x" % x else: - assert 0 != r.exit_code, "unexpected exit code for char 0x%02x" % x + assert 0 == r.exit_code, "unexpected exit code for char 0x%02x" % x + assert 500 == r.response["status"], "unexpected status for char 0x%02x" % x # let the hecho.py CGI echo 0x10 and 0x7f in field name and value def test_h2_200_03(self, env): url = env.mkurl("https", "cgi", "/hecho.py") for h in ["10", "7f"]: r = env.curl_post_data(url, "name=x%%%s&value=yz" % h) - assert 0 != r.exit_code + assert 0 == r.exit_code, "unexpected exit code for char 0x%02x" % h + assert 500 == r.response["status"], "unexpected status for char 0x%02x" % h r = env.curl_post_data(url, "name=x&value=y%%%sz" % h) - assert 0 != r.exit_code - + assert 0 == r.exit_code, "unexpected exit code for char 0x%02x" % h + assert 500 == r.response["status"], "unexpected status for char 0x%02x" % h + # test header field lengths check, LimitRequestLine (default 8190) def test_h2_200_10(self, env): url = env.mkurl("https", "cgi", "/") |