1

I'm attempting to work around an issue with the Coinbase Wallet Chrome extension where it's making incorrect network requests(specifically badly structured eth_chainId request) when trying to add a custom network. I want to intercept these requests and modify them so they're correct.

I'm aware of tools like Requestly, which allow for the modification of network requests from web pages. However, I'm unsure if it's possible to use these tools to modify requests made by other Chrome extensions due to Chrome's security model.

Is there a way to use Requestly or a similar tool to modify network requests made by a Chrome extension? If not, are there any alternative methods or tools I could use to achieve this? I've tried but Requestly does not seem to intercept any of the extension's requests.

For more context, the request the Coinbase wallet extension makes:

curl https://testnet.hashio.io/api \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","method":"eth_chainId"}'

The request it should make(i.e. should have params and id fields in the request body):

curl https://testnet.hashio.io/api \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"method":"eth_chainId","params":[],"id":1,"jsonrpc":"2.0"}'
MShakeG
  • 391
  • 7
  • 45

1 Answers1

2

Browser extension have limitation that they can't listen to traffic from other extensions. That's why Requestly Browser extension can't modify these kind of network requests.

To overcome this limitation, you can use Requestly Desktop App. It offers the same user interface as the browser extension but with additional power and flexibility as as it doesn't face any limitations. Just launch a new chrome instance or connect to an existing one from the Connect Apps, and all the requests will show up in the Network Traffic Page

Requestly Connect Apps

Sahil Gupta
  • 430
  • 5
  • 12