diff --git a/tests/proxy2.py b/tests/proxy2.py index df24a1e7..457866e7 100644 --- a/tests/proxy2.py +++ b/tests/proxy2.py @@ -61,7 +61,7 @@ def get_cert_filepath(path): class ThreadingHTTPServer(ThreadingMixIn, HTTPServer): - address_family = socket.AF_INET # MODIFIED + address_family = socket.AF_INET # MODIFIED to use IPv4 instead of IPv6 daemon_threads = True def handle_error(self, request, client_address): @@ -421,7 +421,7 @@ def test(HandlerClass=ProxyRequestHandler, ServerClass=ThreadingHTTPServer, prot server_address = ('127.0.0.1', port) # MODIFIED: changed from '::1' # MODIFIED: Conditional below added to control INTERCEPT setting. - if len(sys.argv > 2): + if len(sys.argv) > 2: if sys.argv[2].lower() == 'intercept': global INTERCEPT INTERCEPT = True diff --git a/tests/test_proxy_use.py b/tests/test_proxy_use.py index f479c156..6a783c13 100644 --- a/tests/test_proxy_use.py +++ b/tests/test_proxy_use.py @@ -282,10 +282,6 @@ def test_httpS_dl_via_smart_http_proxy(self): Note that the proxy address is still http://... even though the connection with the target server is an HTTPS connection. The proxy itself will act as a TCP proxy via HTTP CONNECT. - - TEMPORARY NOTE: It turns out that mitmproxy doesn't support HTTP CONNECT, - so I need a new proxy option for this.... - """ self.set_env_value('HTTP_PROXY', self.http_proxy_addr2) # http as intended self.set_env_value('HTTPS_PROXY', self.http_proxy_addr2) # http as intended