aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mitmproxy/mitmproxy/protocol/http2.py15
-rw-r--r--mitmproxy/setup.py2
-rw-r--r--test/mitmproxy/fuzzing/.env10
-rw-r--r--test/mitmproxy/fuzzing/straight_stream_patterns1
4 files changed, 5 insertions, 23 deletions
diff --git a/mitmproxy/mitmproxy/protocol/http2.py b/mitmproxy/mitmproxy/protocol/http2.py
index c121637c..3fbc500a 100644
--- a/mitmproxy/mitmproxy/protocol/http2.py
+++ b/mitmproxy/mitmproxy/protocol/http2.py
@@ -9,8 +9,6 @@ from netlib.exceptions import HttpException
from netlib.http import Headers
from netlib.utils import http2_read_raw_frame
-import hyperframe
-import h2
from h2.connection import H2Connection
from h2.events import *
@@ -232,19 +230,6 @@ class Http2Layer(Layer):
stream.zombie = time.time()
return
- frame, _ = hyperframe.frame.Frame.parse_frame_header(raw_frame[:9])
-
- if is_server:
- list = self.server_reset_streams
- else:
- list = self.client_reset_streams
- if frame.stream_id in list:
- # this frame belongs to a reset stream - just ignore it
- if isinstance(frame, hyperframe.frame.HeadersFrame) or isinstance(frame, hyperframe.frame.ContinuationFrame):
- # we need to keep the hpack-decoder happy too
- source_conn.h2.decoder.decode(raw_frame[9:])
- continue
-
events = source_conn.h2.receive_data(raw_frame)
source_conn.send(source_conn.h2.data_to_send())
diff --git a/mitmproxy/setup.py b/mitmproxy/setup.py
index 9d796ebb..e2035a42 100644
--- a/mitmproxy/setup.py
+++ b/mitmproxy/setup.py
@@ -54,7 +54,7 @@ setup(
# It is not considered best practice to use install_requires to pin dependencies to specific versions.
install_requires=[
"netlib=={}".format(version.VERSION),
- "h2>=2.1.0, <2.2",
+ "h2>=2.1.2, <3.0",
"tornado>=4.3, <4.4",
"configargparse>=0.10, <0.11",
"pyperclip>=1.5.22, <1.6",
diff --git a/test/mitmproxy/fuzzing/.env b/test/mitmproxy/fuzzing/.env
index 82ae6a8d..8923b8ae 100644
--- a/test/mitmproxy/fuzzing/.env
+++ b/test/mitmproxy/fuzzing/.env
@@ -1,6 +1,4 @@
-
-MITMDUMP=../../mitmdump
-PATHOD=../../../pathod/pathod
-PATHOC=../../../pathod/pathoc
-FUZZ_SETTINGS=-remTt 1 -n 0
-
+MITMDUMP=mitmdump
+PATHOD=pathod
+PATHOC=pathoc
+FUZZ_SETTINGS="-remTt 1 -n 0"
diff --git a/test/mitmproxy/fuzzing/straight_stream_patterns b/test/mitmproxy/fuzzing/straight_stream_patterns
index 93a066e6..235f2cc3 100644
--- a/test/mitmproxy/fuzzing/straight_stream_patterns
+++ b/test/mitmproxy/fuzzing/straight_stream_patterns
@@ -9,7 +9,6 @@ get:'http://localhost:9999/p/':s'200:b"foo":ir,"\n"'
get:'http://localhost:9999/p/':s'200:b"foo":ir,"a"'
get:'http://localhost:9999/p/':s'200:b"foo":ir,"9"'
get:'http://localhost:9999/p/':s'200:b"foo":ir,":"'
-get:'http://localhost:9999/p/':s"200:b'foo':ir,'\"'"
get:'http://localhost:9999/p/':s'200:b"foo":ir,"-"'
get:'http://localhost:9999/p/':s'200:b"foo":dr'