From 37450173a12e4ecb098cc3255b44279fd282d3ad Mon Sep 17 00:00:00 2001 From: TWY <24794414+t-wy@users.noreply.github.com> Date: Tue, 19 Sep 2023 19:10:28 +0900 Subject: [PATCH] mitmweb: Allow up to 4GB dump to be uploaded (#6373) Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: Maximilian Hils --- CHANGELOG.md | 2 ++ mitmproxy/tools/web/master.py | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b0924b0dd..0c1c4bae4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,8 @@ * Add support for reading HAR files using the existing flow loading APIs, e.g. `mitmproxy -r example.har`. ([#6335](https://github.com/mitmproxy/mitmproxy/pull/6335), @stanleygvi) +* Increase maximum dump file size accepted by mitmweb + ([#6373](https://github.com/mitmproxy/mitmproxy/pull/6373), @t-wy) ## 04 August 2023: mitmproxy 10.0.0 diff --git a/mitmproxy/tools/web/master.py b/mitmproxy/tools/web/master.py index 04daa221f..520cf4d4e 100644 --- a/mitmproxy/tools/web/master.py +++ b/mitmproxy/tools/web/master.py @@ -97,7 +97,9 @@ class WebMaster(master.Master): tornado.ioloop.IOLoop.current() # Add our web app. - http_server = tornado.httpserver.HTTPServer(self.app) + http_server = tornado.httpserver.HTTPServer( + self.app, max_buffer_size=2**32 + ) # 4GB try: http_server.listen(self.options.web_port, self.options.web_host) except OSError as e: