MetaMask / MetaMask/metamask-mobile

Getting "URIs require the appropriate HTTPS prefix" on mobile app only

Open
#6,843 4 comments 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

external-contributor INVALID-ISSUE-TEMPLATE product-backlog team-mobile-platform type-enhancement
Dominant language
TypeScript
Stars
3k
Forks
1.7k
Avg merge
1d 14h
Merged PRs (30d)
669

Description

### Description

MetaMask allows users to enter their own custom RPC endpoints. Those who operate their own node may face an endpoint that doesn't carry an SSL certificate, ie. `http` instead of `https`, depending on their setup. On desktop this presents no error or issues, and works appropriately, but on the mobile app this is not possible, blocked by "URIs require the appropriate HTTPS prefix" when attempting to add the same `http` endpoint, forcing users to use a third-party endpoint.

### Technical Details

An example setup here would be using DAppNode which typically connects through a secure tunnel VPN connection. Once connected to the node securely through the VPN, the users execution client is accessed using an `http` address.

Blocking this forces users to use the default Infura endpoint. Users running their own nodes would often prefer to not query Infura for privacy reasons.

### Acceptance Criteria

Given this is an option on the browser extension app, it would be nice to see the same functionality offered on the mobile app. Offering a warning or note of caution is not a problem in my eyes, but having the option to override and use your own endpoint would be preferred, on par with the browser extension.

Somewhat independent of this it would also be preferred if users could permanently remove the default Infura endpoint. This is for similar reasons, if you're running your own node you often have no reason to ever use this, and it's frustrating to have your own setup and frequently have MetaMask default back to a third-party provider.

Ideally:
- Allow users to add an `http` endpoint, without the warning blocking the user
- Allow the user to remove the default "Ethereum Main Network" entry (or allow users to update the RPC endpoint for the networks that are loaded automatically... in other words, remove the "lock" from these)

### Platform
Android, iOS

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing mobile RPC endpoint validation and the management of automatically loaded networks, then compare those flows with the browser extension behavior described in the issue. Done means users can add an HTTP endpoint with an appropriate warning or override and can remove or edit the default Ethereum Main Network entry on Android and iOS.

Written by the indexing model from the issue text.

Assessment

Tech stack
react-native, typescript
Domain
blockchain, mobile
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.