Skip to content

Add support for deriving Solana root account (m/44'/501') in Seed Vault - #636

Open
joaopeixoto13 wants to merge 1 commit into
solana-mobile:mainfrom
joaopeixoto13:main
Open

Add support for deriving Solana root account (m/44'/501') in Seed Vault#636
joaopeixoto13 wants to merge 1 commit into
solana-mobile:mainfrom
joaopeixoto13:main

Conversation

@joaopeixoto13

Copy link
Copy Markdown

This PR extends Solana account discovery by deriving and registering the root-level BIP44 account at path m/44'/501'. Previously, only indexed accounts (m/44'/501'/X' and m/44'/501'/X'/0') were discovered.

Changes:

  • Added root derivation path construction using BIP44 purpose and coin type.
  • Derived root public key using full partial-derivation.
  • Added root account insertion into knownAccounts if not already stored.
  • Preserved existing logic for Type-1 and Type-2 accounts.
  • Improved log messages for clarity and consistency.

This enables compatibility with wallets that treat the base path m/44'/501' as a valid Solana address (e.g., Ledger).

This commit extends Solana account discovery by deriving and registering
the root-level BIP44 account at path m/44'/501'. Previously, only
indexed accounts (m/44'/501'/X' and m/44'/501'/X'/0') were discovered.

Changes:
- Added root derivation path construction using BIP44 purpose and coin
type.
- Derived root public key using full partial-derivation.
- Added root account insertion into knownAccounts if not already stored.
- Preserved existing logic for Type-1 and Type-2 accounts.
- Improved log messages for clarity and consistency.

This enables compatibility with wallets that treat the base path
m/44'/501' as a valid Solana address.

Signed-off-by: João Peixoto <joaopeixotooficial@gmail.com>
@sdlaver

sdlaver commented Nov 18, 2025

Copy link
Copy Markdown
Contributor

Hi João, thanks for opening a pull request for this.

I wanted to clarify one thing - the function you are modifying is only the default set of derived accounts, not the allowed set of accounts. ACTION_GET_PUBLIC_KEY (

public static final String ACTION_GET_PUBLIC_KEY = AUTHORITY_WALLET + ".ACTION_GET_PUBLIC_KEY";
) can be used to derive any desired derivation path from the root. The convenience helper to invoking this can also be found here: .

There are 2 real implementations of Seed Vault in the wild; Saga and Seeker. Both of these derive the default set of accounts according to the current logic: m/44'/501'/X' and m/44'/501'/X'/0'.

I'd request that you move this to a GitHub issue first, so we can discuss this change further. For example, I'm curious which wallet app consumers of the Seed Vault API would want to have this derivation path as part of the default set?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants