Note: This guide is for Ledger Nano S but according to community members it also works for Ledger Nano X.
- This guide assumes you have a verified, genuine Ledger Nano S device.
- If you don't, or you using your Ledger device for the first time, you should check Ledger's Getting Started guide.
- We also advise you to check your Ledger's genuineness and upgrade your firmware to the newest one available (
v1.6.0+
). - Have a machine with Ledger Live installed.
- Have the latest version of our latest binaries installed. You can get it here.
- Open Ledger Live and go to Settings (gear icon on the top right corner):
- Enable developer mode:
- Now go to Manager and search "Cosmos":
- Our binaries require Cosmos App Version
1.5.1
(if you only see a lower version available, like1.0.0
, then you need to upgrade your Ledger firmware). - Hit "Install" and wait for the process to complete.
Ref: https://github.com/cosmos/ledger-cosmos
These are some basic examples of commands you can use with your Ledger. You may notice that most commands stay the same, you just need to add the --ledger
flag.
Note: To run these commands below, or any command that requires signing with your Ledger device, you need your Ledger to be opened on the Cosmos App:
Ref: https://medium.com/cryptium-cosmos/how-to-store-your-cosmos-atoms-on-your-ledger-and-delegate-with-the-command-line-929eb29705f
- Prepare your Linux host to work with ledger
Some users may not have their ledger recognized by their Linux host. To fix this issue implement the fix for connection issues on Linux from the ledger support page
wget -q -O - https://raw.githubusercontent.com/LedgerHQ/udev-rules/master/add_udev_rules.sh | sudo bash
- MacOS
You will need at least MacOS 10.14 Mojave, which introduced the Security feature of allowing Full Disk Access, which Ledger Live needs in order to enable the --ledger
flag in secretcli
. Refer to the MacOS section in the ledger support page.
We recommend using Keplr Wallet as the interface for using Ledger with the Secret Network. To use, simply install the extension, and select "Import Keplr" when adding a new account
For a more advanced user, it is possible to interface with the CLI utility, SecretCLI with a Ledger device. You can get it here
Note: You can use any number you'd like for your account number. Be sure to remember the number you used, so you can recover if needed.
secretcli keys add <account name> --ledger --account <account number on your Ledger> --legacy-hd-path
Please backup the mnemonics!
Note: Ledger only supports a BIP-44 HD path of
44'/118'/{account}'/0/{index}
, while Secret Network wallets will use44'/529'/{account}'/0/{index}
by default. This means if you wish to export the keys to a different wallet, you must select 118 as the coin type when importing the mnemonics
secretcli keys show -a <account name>
You'll use this when you, say, using a different machine.
secretcli keys add <account name> --ledger --account <account number on your Ledger> --recover --legacy-hd-path
Note! If you run the above command without the --ledger
flag, the CLI will prompt you to enter your BIP39 mnemonic, which is your Ledger recovery phrase. YOU DO NOT WANT TO DO THIS. This will essentially save your private key locally.
Note: the commands below assume that you run them on the same machine where you have an Secret Network node running. However, if you need to connect to a remote Secret Network node (on the cloud) while you interact with your Ledger wallet locally, you will need to append the following to each command below:
--node http://node.domain:26657
secretcli tx send <account name or address> <to_address> <amount> --ledger
secretcli tx staking delegate <validator address> <amount to bond> --from <account key> --ledger
secretcli tx distribution withdraw-all-rewards --from <account name> --gas auto --commission --ledger
secretcli tx gov vote <proposal-id> <vote> --from <account name> --ledger