question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Proxies should use proxy_ssl_context when connecting via ProxyConfig.use_forwarding_with_https = True

See original GitHub issue

This was discovered in https://github.com/urllib3/urllib3/pull/2558 and discussed with @jalopezsilva on Discord. The gist is it appears that we’re using HTTPSConnection.ssl_context to connect to HTTPS proxies when using use_forwarding_with_https = True mode. This is likely caused by us treating the proxy like it’s the origin when we have proxies in “forwarding” mode and previously we didn’t have a forwarding mode for HTTPS.

Minimum requirements

💵 You can get paid to complete this issue! Please read the docs for more information.

  • When ProxyConfig.use_forwarding_with_https = True and ssl_context is specified:
    • If proxy_ssl_context is specified then error out with ValueError
    • If proxy_ssl_context isn’t specified:
      • On 1.26.x emit a DeprecationWarning instructing to switch to proxy_ssl_context and set the value of ssl_context to proxy_ssl_context
      • On 2.x raise a ValueError that proxy_ssl_context should be used, not ssl_context.
  • Only proxy_ssl_context should be used for creating the connection to proxies in all modes (HTTP->HTTPS, HTTPS->HTTP, HTTPS->HTTPS, in forwarding/tunnel modes).
  • Remove the skip to test_proxy_https_target_tls_error added in https://github.com/urllib3/urllib3/commit/9f4d05c11eb2f80682c1b7a2671b0636292ef932

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
sethmlarsoncommented, Aug 19, 2022

@umarfarouk98 this issue is already being worked on by @avi364 I think in #2651?

0reactions
fyunusacommented, Aug 19, 2022

OK yeah, I see that

Read more comments on GitHub >

github_iconTop Results From Across the Web

angular-cli server - how to proxy API requests to another server?
To my knowledge with Angular 2.0 release setting up proxies using .ember-cli ... option then the target option is not used so it...
Read more >
Mastering Angular proxy configuration | by JM Robles - Medium
To use the angular proxy you need to define a configuration file and pass it when ... to true (change the Host header...
Read more >
Proxy not working when running ng serve · Issue #4676 - GitHub
Need to run a proxy so I added --proxy-config proxy.conf.json in ... problem is that incoming connections when --host=0.0.0.0 is used?
Read more >
Configure a proxy for your API calls with Angular CLI - | juri.dev
To set it up, we need to create a file proxy.conf.json at the root of our Angular CLI project. The content should look...
Read more >
How to resolve CORS errors by using Angular Proxy?
So here, I will describe all the details in this article and will also show you simple and easy ways to overcome this...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found