Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request for proxy headers #2552

Open
benoist opened this issue Feb 11, 2025 · 1 comment
Open

Request for proxy headers #2552

benoist opened this issue Feb 11, 2025 · 1 comment
Labels
C-feature Category: feature. This is requesting a new feature. E-pr-welcome The feature is welcome to be added, instruction should be found in the issue.

Comments

@benoist
Copy link

benoist commented Feb 11, 2025

Hi,

Thanks for maintaining this great crate!

I was looking at the options to add custom proxy headers in the CONNECT phase, but I see only user agent and proxy-authentication are sent in the tunnel method.

Could we for example extend the ProxyScheme struct to allow setting custom headers as well?

Just like with curl you can do --proxy-header and specify customer headers.

This is useful when using a rotating proxy and you want to hint the proxy rotator with some info about what type of proxies to use.

@seanmonstar seanmonstar added E-pr-welcome The feature is welcome to be added, instruction should be found in the issue. C-feature Category: feature. This is requesting a new feature. labels Feb 18, 2025
@seanmonstar
Copy link
Owner

This seems like a fair request. By adding a new method, similar to Proxy::basic_auth(), but Proxy::headers(HeaderMap).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-feature Category: feature. This is requesting a new feature. E-pr-welcome The feature is welcome to be added, instruction should be found in the issue.
Projects
None yet
Development

No branches or pull requests

2 participants