Skip to content

LedgerHQ/app-helium-solana

 
 

Repository files navigation

Build Status

Solana-compatible Helium app for Ledger Wallet

Overview

This app provides support for the Solana Network for Helium accounts. It is a simple clone of the default Solana Ledger app, but with the Helium's derivation path. For new accounts, it is encouraged to use the regular Solana Ledger app.

Current Features:

  • Pubkey queries
  • Parse, display and sign all Solana CLI generated transaction formats
  • Blind sign arbitrary transactions (Enabled via settings)

Prerequisites

For building the app

Build the Ledger App Builder Docker image

  1. Clone the git repository
git clone https://github.com/LedgerHQ/ledger-app-builder.git
  1. Change directories
cd ledger-app-builder
  1. Checkout the target commit
git checkout 73c9e07
  1. Build the image
docker build -t ledger-app-builder:73c9e07 .
  • If permissions errors are encountered, ensure that your user is in the docker group and that the session has been restarted

For working with the device

Install Python3 PIP

Ubuntu Linux:

sudo apt install pip3

MacOS

brew install python3

Install ledgerblue python module

pip3 install ledgerblue

Locally clone SDK repos corresponding to those included in the Docker image

  • Setup environment
cat >>"${HOME}"/.profile <<EOF
LEDGER_SDK_BASE_PATH= # set to a writable path
: "${LEDGER_SDK_BASE_PATH:?}"
export NANOS_SDK="${LEDGER_SDK_BASE_PATH}"/nanos-secure-sdk
export NANOX_SDK="${LEDGER_SDK_BASE_PATH}"/nanox-secure-sdk
export NANOSP_SDK="${LEDGER_SDK_BASE_PATH}"/nanosplus-secure-sdk
EOF
  • Update the current session's environment
. "${HOME}"/.profile # Or close and reopen your terminal
  • Clone the repositories
# Nano S SDK
git clone --branch 2.1.0 --depth 1 https://github.com/LedgerHQ/nanos-secure-sdk.git "${NANOS_SDK}"

# Nano X SDK
git clone --branch 2.0.2-2 --depth 1 https://github.com/LedgerHQ/nanox-secure-sdk.git "${NANOX_SDK}"

# Nano S+ SDK
git clone --branch 1.0.3 --depth 1 https://github.com/LedgerHQ/nanosplus-secure-sdk.git "${NANOSP_SDK}"

For running the test suite

Build

It is highly recommended that you read and understand the Ledger App Builder build process before proceeding. A convenience wrapper script (./docker-make) has been provided for simplicity

docker-make manages the current target SDK for you, automatically setting BOLOS_SDK to the correct path when the Docker container is launched. A TARGET_SDK must be specified when building from clean and clean must be run before switching

TARGET_SDK

Moniker Device
s Nano S
x Nano X
sp Nano S+
./docker-make <TARGET_SDK>

Clean

./docker-make clean

Working with the device

Requires that the BOLOS_SDK envvar be set. This can be achieved by first building for the desired target device.

Load

make load-only

Delete

make delete

Test

Unit

Run C tests:

make -C libsol

Integration

First enable blind-signing in the App settings

cargo run --manifest-path tests/Cargo.toml

Packages

No packages published

Languages

  • C 77.5%
  • Rust 11.6%
  • Python 5.0%
  • C++ 3.6%
  • Makefile 1.0%
  • Shell 1.0%
  • CMake 0.3%