tabame
tabame copied to clipboard
Persistent crash upon switching networks to OysterLending
Steps to reproduce:
- Run locally with
HTTPS=true npm start
- Open https://localhost:3000
- Open settings menu
- From Networks select, choose "OysterLending"

Because the chosen network is set in localStorage, the crash will persist upon reloading the page, and clearing localStorage is the only way to recover.
From my debugging, it looks like the root issue is this:
Mixed Content: The page at 'https://localhost:3000/#/' was loaded over HTTPS, but requested an insecure resource 'http://oyster-dev.solana.com/'. This request has been blocked; the content must be served over HTTPS.
Mixed Content: The page at 'https://localhost:3000/#/' was loaded over HTTPS, but attempted to connect to the insecure WebSocket endpoint 'ws://oyster-dev.solana.com/'. This request has been blocked; this endpoint must be available over WSS.
Access over HTTPS is required for WebUSB support (e.g. https://github.com/solana-labs/oyster-lending/pull/56)
Promixate cause is probably HTTP access of this link:
https://github.com/solana-labs/oyster-lending/blob/6ce7798fa75bd4cb89219d45e3e49716d20ae2be/src/contexts/connection.tsx#L30
However, the HTTPS version of this link doesn't resolve.