From 2d68a5246a2112531556611f84f0b297c8f7438b Mon Sep 17 00:00:00 2001 From: Sujal Singh Date: Mon, 18 Nov 2024 15:24:14 +0530 Subject: [PATCH] remove hard coded default window size for HTTP/2 connections. (#7333) --- mitmproxy/proxy/layers/http/_http_h2.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mitmproxy/proxy/layers/http/_http_h2.py b/mitmproxy/proxy/layers/http/_http_h2.py index ee76ddb68..d554eeb83 100644 --- a/mitmproxy/proxy/layers/http/_http_h2.py +++ b/mitmproxy/proxy/layers/http/_http_h2.py @@ -61,7 +61,9 @@ class BufferedH2Connection(h2.connection.H2Connection): super().initiate_connection() # We increase the flow-control window for new streams with a setting, # but we need to increase the overall connection flow-control window as well. - self.increment_flow_control_window(2**31 - 1 - 65535) # maximum - default + self.increment_flow_control_window( + 2**31 - 1 - self.inbound_flow_control_window + ) # maximum - default def send_data( self,