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
Add authorization for http and websocket #829
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks for this,
some suggestions and few nits
Thanks for your feedback! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
last nit but lgtm!
Thanks a lot! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
very nice
Summary
This pull request adds basic and bearer authentication for http and non-wasm websockets transport.
Motivation
Some people operate their node behind a reverse-proxy which uses some form of authentication. This pull request makes it possible to use ethers-rs in this case.
Solution
The solution is to inject auth headers into http requests and the websocket handshake request.
PR Checklist