Skip to content

fix(sdk): require HTTPS for bearer tokens - #2961

Open
felix314159 wants to merge 1 commit into
succinctlabs:mainfrom
felix314159:fix/bearer-token-require-https
Open

felix314159 wants to merge 1 commit into
succinctlabs:mainfrom
felix314159:fix/bearer-token-require-https

Conversation

@felix314159

Copy link
Copy Markdown

Summary

  • reject plaintext RPC URLs when a bearer token is configured
  • preserve plaintext endpoints for clients without transport credential
  • document the HTTPS requirement on the async and blocking network prover builders

Motivation

NetworkProverBuilder supports both custom RPC URLs and bearer-token authentication. before this pr, combining a bearer token with an http:// RPC URL caused the SDK to send the reusable Authorization credential over a plaintext HTTP/2 connection, so a malicious network observer would have been able to recover the token and use any privileges it grants until it expires or is refreshed..

the endpoint already requires HTTPS for mTLS client identities, so this change applies the same transport requirement to bearer tokens and returns an error before creating the plaintext connection.

This branch has not been deployed

No deployments
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

Successfully merging this pull request may close these issues.

1 participant