Stack Wallet, a multicoin, cryptocurrency wallet
Find a file
sneurlax 4aec78f0ed
Add BIP44 derivation paths to Bitcoin Cash wallet restoration process (#330)
* add new derive path for bch

and make it the new default.  we currently use slip44 (coinType 145) as the default

* add default cases to DerivePathType switches now failing

* normalize DerivePathType errors

log failing derivePathType or type, as appropriate

* add default derive path case to paynym interface

* use slip44 in bch wallet

* linting

* WIP look up both bip44 and slip44 addresses

slip44 is used by default

* typo fix

* typo fix

thanks Julian

* remove print

* use slip44 addresses by default

* use AddressType unknown for bip44 derive path type

* use address type unknown in _getCurrentAddressForChain, too

* generate different keys for SLIP44 and BIP44 paths

* couple more slips

* return slip44 from addressType

* slip before bip

* revert slip44-bip44, bch's bip44->bch44

* set bch44 derive path to type unknown

do not comingle paths in later output selection by index

* handle bip44 and bch44 path addresses when handling outputs

* use bip44 by default

* typofix

* typo fix in the typo fix

yo dawg

* separate new derivation path functions into their own non-testnet block

* cleanup

* disable test

should re-enable if it can be fixed with the test mnemonic in hand

---------

Co-authored-by: julian <julian@cypherstack.com>
2023-02-02 09:24:26 -06:00
.github/workflows Update test.yaml 2022-12-12 16:10:19 -06:00
.vscode first commit 2022-08-26 16:11:35 +08:00
android Remove Stack Wallet from list of apps with which to open file on Android (#268) 2022-12-16 07:41:37 -06:00
assets update sorbet theme images 2023-01-31 18:31:14 -06:00
crypto_plugins "choose from stack" fixes 2023-01-31 08:41:40 -06:00
google_fonts font fix 2022-09-24 15:21:31 -06:00
integration_test first commit 2022-08-26 16:11:35 +08:00
ios Update ios version stuff 2023-01-06 17:31:28 -07:00
lib Add BIP44 derivation paths to Bitcoin Cash wallet restoration process (#330) 2023-02-02 09:24:26 -06:00
linux reduce minimum height and set starting height lower on linux 2022-11-24 18:22:45 -06:00
macos add paynym share 2023-02-01 10:08:30 -06:00
scripts Building (#277) 2022-12-30 12:30:11 -06:00
test Add BIP44 derivation paths to Bitcoin Cash wallet restoration process (#330) 2023-02-02 09:24:26 -06:00
windows add paynym share 2023-02-01 10:08:30 -06:00
.gitignore coin tests code error cleanup 2023-01-19 13:47:51 -06:00
.gitmodules added back the crypto_plugins 2022-08-26 16:15:29 +08:00
.metadata first commit 2022-08-26 16:11:35 +08:00
analysis_options.yaml possible fix for monero syncing bug 2022-08-28 00:06:04 +08:00
dockerfile.linux Building (#277) 2022-12-30 12:30:11 -06:00
LICENSE first commit 2022-08-26 16:11:35 +08:00
pubspec.lock add paynym share 2023-02-01 10:08:30 -06:00
pubspec.yaml add paynym share 2023-02-01 10:08:30 -06:00
README.md Use flutter version 3.3.4 2022-11-30 08:24:21 -08:00

codecov

Stack Wallet

Stack Wallet is a fully open source cryptocurrency wallet. With an easy to use user interface and quick and speedy transactions, this wallet is ideal for anyone no matter how much they know about the cryptocurrency space. The app is actively maintained to provide new user friendly features.

Playstore

Feature List

Highlights include:

  • 5 Different cryptocurrencies
  • All private keys and seeds stay on device and are never shared.
  • Easy backup and restore feature to save all the information that's important to you.
  • Trading cryptocurrencies through our partners.
  • Custom address book
  • Favorite wallets with fast syncing
  • Custom Nodes.
  • Open source software.

Building

Prerequisites

  • The only OS supported for building is Ubuntu 20.04
  • A machine with at least 100 GB of Storage

The following prerequisities can be installed with the setup script scripts/setup.sh or manually as described below:

Scripted setup

scripts/setup.sh is provided as a tool to set up a stock Ubuntu 20.04 installation for building: download the script and run it anywhere. This script should skip the entire Manual setup section below and prepare you for running. It will set up the stack_wallet repository in ~/projects/stack_wallet and build it there.

Manual setup

After installing the prerequisites listed above, download the code and init the submodules

git clone https://github.com/cypherstack/stack_wallet.git
cd stack_wallet
git submodule update --init --recursive

Install all dependencies listed in each of the plugins in the crypto_plugins folder (eg. flutter_libmonero, flutter_libepiccash ) as of Oct 3rd 2022 that is:

sudo apt-get install unzip automake build-essential file pkg-config git python libtool libtinfo5 cmake openjdk-8-jre-headless libgit2-dev clang libncurses5-dev libncursesw5-dev zlib1g-dev llvm sudo apt-get install debhelper libclang-dev cargo rustc opencl-headers libssl-dev ocl-icd-opencl-dev

Install Rust

cargo install cargo-ndk
rustup target add aarch64-linux-android armv7-linux-androideabi i686-linux-android x86_64-linux-android

sudo apt install libc6-dev-i386
sudo apt install build-essential cmake git libgit2-dev clang libncurses5-dev libncursesw5-dev zlib1g-dev pkg-config llvm 
sudo apt install build-essential debhelper cmake libclang-dev libncurses5-dev clang libncursesw5-dev cargo rustc opencl-headers libssl-dev pkg-config ocl-icd-opencl-dev
sudo apt install unzip automake build-essential file pkg-config git python libtool libtinfo5 cmake openjdk-8-jre-headless

Run prebuild script

cd scripts
./prebuild.sh
// when finished go back to the root directory
cd ..

Remove pre-installed system libraries for the following packages built by cryptography plugins in the crypto_plugins folder: boost iconv libjson-dev libsecret openssl sodium unbound zmq. You can use

sudo apt list --installed | grep boost

for example to find which pre-installed packages you may need to remove with sudo apt remove. Be careful, as some packages (especially boost) are linked to GNOME (GUI) packages: when in doubt, remove -dev packages first like with

sudo apt-get remove '^libboost.*-dev.*'

Building plugins for Android

cd scripts/android/
./build_all.sh
// when finished go back to the root directory
cd ../..

Building plugins for Linux

cd scripts/linux/
./build_all.sh
// when finished go back to the root directory
cd ../..

Running

Android

Plug in your android device or use the emulator available via Android Studio and then run the following commands:

flutter pub get
flutter run android

Note on Emulators: Only x86_64 emulators are supported, x86 emulators will not work

Linux

Plug in your android device or use the emulator available via Android Studio and then run the following commands:

flutter pub get Linux
flutter run linux

Android Studio

Android Studio is the recommended IDE for development, not just for launching on Android devices and emulators but also for Linux desktop development. Install it and configure it as follows:

# setup android studio
sudo apt install -y openjdk-11-jdk
sudo snap install android-studio --classic

Use Tools > SDK Manager to install the SDK Tools > Android SDK (API 30), SDK Tools > NDK, SDK Tools > Android SDK command line tools, and SDK Tools > CMake

Then install the Flutter plugin and restart the IDE. In Android Studio's options for the Flutter language, enable auto format on save to match the project's code style. If you have problems with the Dart SDK, make sure to run flutter in a terminal to download it (use source ~/.bashrc to update your environment variables if you're still using the same terminal from which you ran setup.sh)

Make a Pixel 4 (API 30) x86_64 emulator with 2GB of storage space for emulation