Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
…26203) ## **Description** Pass along hashed `rpcUrl` when added as a custom network. We are hashing the rpcUrl for privacy reasons, so that no custom `rpcUrls` get leaked. For instance, this would be important for those running their own ETH nodes. When leveraging this new value, analytics should also hash `rpcUrls` of common rpc's on chainlist, then compare the hashes. Note that I opted _not_ to use the `URL` constructor, since it will enforce trailing `/` on base urls when I am noticing that most urls on `chainlist` do not have this: https://chainlist.org/chain/1 [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/26203?quickstart=1) ## **Related issues** Fixes: MMASSETS-298 mobile PR also needs to be added. ## **Manual testing steps** Add CustomNetwork and ensure that the proper payload is sent in the network tab when `CustomNetworkAdded` event fires off. ## **Screenshots/Recordings** N/A ## **Pre-merge author checklist** - [x] I've followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md). - [x] I've completed the PR template to the best of my ability - [x] I’ve included tests if applicable - [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [x] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed). - [ ] I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots. --------- Co-authored-by: Brian Bergeron <[email protected]>
- Loading branch information