Skip to content

Commit

Permalink
feat(iroh-net)!: Implement http proxy support (#2298)
Browse files Browse the repository at this point in the history
Headers are based on how `curl` and env variables on`reqwest`.

Setting any of 

- `HTTP_PROXY`
- `http_proxy`
- `HTTPS_PROXY`
- `https_proxy`

will make all relay code use these to proxy outgoing connections.

Closes #2295 

## Breaking Changes

- Added `iroh_net::endpoint::Builder::proxy_url`
- Added `iroh_net::endpoint::Builder::proxy_from_env`
- Added `iroh_net::relay::http::ClientError::Proxy` enum variant

## TODOs

- [x] config & parsing env variables
- [x] the todos in the code
- [x] https proxy 
- [x] testing: tested manually on two machines using `squid`
  • Loading branch information
dignifiedquire authored May 22, 2024
1 parent db0d2e7 commit 8d21b5a
Showing 1 changed file with 378 additions and 251 deletions.
Loading

0 comments on commit 8d21b5a

Please sign in to comment.