sRFC 00011: A standard for implementing multi-chain SVM support in Solana Wallets
This sRFC proposes a standard for implementing multi-chain SVM(eg: Eclipse chains) support in Solana Wallets, allowing Solana applications (“dapps”) to suggest chains to be added to the user’s wallet application. This enables convenient interaction with dapps on testnets, canary chains, or other SVM chains without requiring complex manual custom RPC changes. The standard aims to streamline the process and prevent inconsistencies across multiple standards and one-off implementations.
Inspired by EIP-3085, this design allows Solana applications to suggest chains to be added to the user’s wallet application. The wallet application may arbitrarily refuse or accept the request. We have received a request for this feature from many dapps.
Unlike Ethereum, Solana doesn’t have chain ids that are used to prevent replay attacks. Here is the solution we propose to have multichain support while not introducing breaking changes to Solana.
Solution A: Whitelist Registry
eg:- On Keplr, when you first create a wallet, you get 10 of the most popular cosmos chains added by default; it would also make sense to do this for Solana wallets with SVM chains.
The workflow for adding new chains should be like this: User clicks add chain → Wallet checks if the RPC is whitelisted → New chain is added.
Question: Where would we want to store the registry of the whitelisted RPCs?
- A. We could ship it with the wallet if it’s a low number(<50).
- B. If it’s larger, put it on a database like Postgres or something decentralized like Arweave, IPFS, etc.
More technical details
- Solana Wallet Standard: At first glance there are some changes needed to the Solana wallet standard. There are places where the wallet is required to return all chains that it supports, so we would need some interface for the dapp to pass back a new chain to be added: wallet-standard/account.ts at master · solana-labs/wallet-standard · GitHub This change seems like it could be made immediately if it is done in a non-breaking way. The wallet should not be required to add a chain even if the dapp requests it.
- Wallet Adapter: We would need to make some change to the wallet adapter so the dapp can specify the desired RPC network. This would need to be rolled out after the Wallet Standard change.
- Dapp Support: The dapp updates their Wallet Adapter library and specify their desired RPC network. If no RPC network is specified, by default this change has no effect - the behavior is exactly the same as SVM wallets function right now (default to Solana mainnet). This is the last change to occur.
Github discussion: https:// github. com/solana-labs/wallet-standard/issues/9
Backpack PR: https:// github. com/coral-xyz/backpack/pull/3730