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

Remove previous Authorization header #7

Closed
rcastill opened this issue Sep 13, 2022 · 2 comments
Closed

Remove previous Authorization header #7

rcastill opened this issue Sep 13, 2022 · 2 comments

Comments

@rcastill
Copy link
Contributor

I have the following use-case:

User gives authenticated url. Something like this: http://user:pass@host:port/path

If request is submitted with such an Url with reqwest, it will automatically form the "Authorization" header, assuming it's basic authentication.

The idea is to be able to "automatically detect" if it is basic auth or digest auth.

In order to implement this, send_with_digest_auth() could remove any previous "Authorization" headers set. But I'm not sure if this is possible. Maybe reqwest adds the header after send_with_digest_auth() acts.

Is this even something that diqwest should handle?

Maybe this issue can be brought to reqwest itself?

@maoertel
Copy link
Owner

Hey @rcastill,

I really have to look into my notification setup 🤦🏾

If you are interested to handle it I encourage you to open a PR and then let's discuss.

✌🏾

@maoertel
Copy link
Owner

Closing this as to my feeling it does not fall into the responsibility of this crate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants