Closed Scartzz closed 3 years ago
Hello there! Thanks for taking the time to report the issue.
From what I've googled quickly, it might be because you are trying to access the proxy over HTTPS instead of HTTP. The current proxy only supports HTTP, although it can tunnel 'blindly' https.
It is in my plans to support HTTPS with a self signed certificate (#278) in the future though.
I'll dig more into it tomorrow, thanks for your patience!
Hello! Thank you for your prompt reply.
I start the MITM Proxy with following Options:
options.Options(listen_host='0.0.0.0', listen_port=8080, mode='upstream:http://' + container.ip_address + ':8888', ssl_insecure=True)
If you have not yet used the MITM proxy, this means that I use the proxy via "http://172.17.0.16:8888". So via HTTP. When I make requests via Python with the Requests Lib through the MITM proxy, everything works normally. Mybe it's only a bug in MITM Proxy, but everything works with the image in v3.5.1.
v3.6 has an http proxy I wrote from scratch, that's probably why we are seeing some issues.
I'm planning this weekend on supporting an HTTPS proxy with a self signed certificate maybe that can solve it.
In the meantime can you try setting the MITMproxy option ssl_version_client='all'
to see what happens? I'm really wondering what tls/SSL has to do here 🤔
This seems to be an issue with HTTPs handling in the proxy I think, although it's a bit odd.
Can you try running for example:
docker run -it --rm alpine:3.12
curl --proxy http://youruser:yourpassword@yourdockerhostip:8888 -vvv https://raw.githubusercontent.com/qdm12/gluetun/master/.github/CODEOWNERS
exit
What does it give you? For me it works but it doesn't for someone else (see #298)
Let's continue the discussion on #298 which in my opinion is the same problem. I'm closing this one to simplify tracking and discussion.
Host OS: Ubuntu 20
Is this urgent?: No, but a quick fix would be nice
What VPN provider are you using: PIA
What are you using to run your container?: Docker Compose
What is the version of the program (See the line at the top of your logs)
What's the problem 🤔
I use the container behind a MITM (https://github.com/mitmproxy/mitmproxy) Proxy Container. I think the program I use is quite old and probably uses an older SSL / TLS version.
In my setup, the program first sends the requests to a MITM proxy where the requests are rewritten and possibly also redirected. The MITM proxy runs in upstream mode on the VPN container. So far this has worked perfectly up to version 3.5.1. But since v.3.6.0 (probably the newly written HTTP proxy) I don't get any more answers, but an weird...
... Error. Any other Requests e.g. with python-requests or Firefox run without problems.
Is the SSL library or the program used simply too old or am I doing something wrong? The used SSL Lib from MITM Proxy is up to date. I have already checked this several times.
This is the first time I've reported a bug. Please excuse any misstakes in this.
Share your logs...
...careful to remove i.e. token information with PIA port forwarding