Giter Club home page Giter Club logo

zcash-mini's Introduction

zcash-mini

zcash-mini is a minimal, portable Zcash wallet generator in Go.

$ go get -u github.com/FiloSottile/zcash-mini

 - or -

$ git clone https://github.com/FiloSottile/zcash-mini
$ cd zcash-mini && make && sudo cp ./bin/zcash-mini /usr/local/bin/
$ zcash-mini

###############################################################
#
#  Here is your z-address
#
#      zchb1pjPZj5km3arxocST98jY27BzFqiaK2f7vLgyYgStPSuQ1dVR97ahfbz51oQM3Xb8VooGh9E5dyfMN2SJ1q1HVcsExT
#
###############################################################
#
#  Here is the secret spending key
#
#      SKxtAQQL74P5HMN73niHX1YwYZbjBMBPzp8NQ2M35Z2TybUbjiKc
#
#  KEEP IT SAFE, IT HAS NOT BEEN SAVED ANYWHERE
#
#  To spend, import the secret key with
#
#      zcash-cli z_importkey KEY rescan
#
###############################################################
#
#  The following is a mnemonic encoding of the secret key
#  which you can write down as a paper wallet
#
#      armed fortune seek athlete humor please margin prosper
#      spend stool weapon buzz verify radio hamster couple
#      exercise idea stock year elder pass dune aspect
#
#  Run "zcash-mini -mnemonic" to rebuild your secret key
#
###############################################################
#
#  Finally, here is the viewing key
#
#      112TXSCh37UifeAJMmf7jcDpRiGp7krSggfqRVWqSYQNwrL8wj2Y
#
#  (not yet supported by the full node)
#
###############################################################

To re-process an existing key instead of generating a new one, use -key.

To generate vanity addresses use -prefix or the very, very slow -regexp. There is no GPU support, so you won't get the performance you would get with other implementations (which I have not used or reviewed).

To get script-friendly output use -simple.

To cross compile simply run e.g. GOOS=linux GOARCH=arm make.

This is experimental software and it will eat your money, your hard drive and your pets.

Use cases

  • offline and paper wallets
  • non-Linux amd64 environments (Raspberry Pi, OpenBSD, ...)
  • machines without the resources to run a full node

Features

  • offline generation of z-address wallets
  • vanity addresses
  • paper wallet / mnemonic generation
  • 300 LoC, easy to review
  • pure Go, easy to cross-compile / deploy

Balance management and spending operations are not supported.

Intended workflow

  • generate a z-address with zcash-mini on a secure machine
  • optionally write down the 24 words as a paper wallet
  • receive Zcash on a t-address in a full node
  • send the Zcash to the z-address yourself
  • to spend the Zcash, export the private key to a full node

zcash-mini's People

Contributors

alfiedotwtf avatar filosottile avatar zmanian avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

zcash-mini's Issues

not sure how to fix this error

 ~ $ cd zcash-mini && make && sudo cp ./bin/zcash-mini /usr/local/bin/
go install -v -ldflags='-X "main.Version=a2b3504" -X "main.BuildTime=2018-01-26-1238 UTC"' github.com/FiloSottile/zcash-mini
.GOPATH/src/github.com/FiloSottile/zcash-mini/zcash/address.go:10:2: cannot find package "github.com/btcsuite/btcutil/base58" in any of:
	/usr/lib/go/src/pkg/github.com/btcsuite/btcutil/base58 (from $GOROOT)
	/home/daeng/zcash-mini/.GOPATH/src/github.com/btcsuite/btcutil/base58 (from $GOPATH)
.GOPATH/src/github.com/FiloSottile/zcash-mini/zcash/address.go:11:2: cannot find package "golang.org/x/crypto/curve25519" in any of:
	/usr/lib/go/src/pkg/golang.org/x/crypto/curve25519 (from $GOROOT)
	/home/daeng/zcash-mini/.GOPATH/src/golang.org/x/crypto/curve25519 (from $GOPATH)
Makefile:10: recipe for target 'zcash-mini' failed
make: *** [zcash-mini] Error 1

note: I'm a layman

Should also export a viewing key

The Zcash protocol also has support for view keys. Views keys can determine if a tx has been received but not spend them.

I don't believe there is any support for view keys in the full node wallet yet but we could generate and export a view key that could immediately be imported by a user's full node.

Fatal error on certain phrases

try zcash-mini -mnemonic with phrase

polar donate street struggle shrimp sugar december absurd thunder dinner help disagree nominee napkin dove jaguar electric carpet donate bamboo size ride popular multiply

you'll get
[FATAL] Error: invalid key: must be 32 bytes with first 4 bits set to 0

Vanitygen option

It would be cool if this had a vanity option so that the z-address matched a requested format.

You mentioned that you had some of this in branch. If you could copy-paste this into a gist or a different branch, I can try and get it working.

Utility does not build

go version go1.16.6 linux/amd64

$ git clone https://github.com/FiloSottile/zcash-mini
$ cd zcash-mini    
$ make
go install -v -ldflags='-X "main.Version=a2b3504" -X "main.BuildTime=2021-08-26-1120 UTC"' github.com/FiloSottile/zcash-mini
go install: version is required when current directory is not in a module
    Try 'go install github.com/FiloSottile/zcash-mini@latest' to install the latest version
make: *** [Makefile:10: zcash-mini] Error 1

Existing key mode

It should be possible to provide a key and get address and view key

zcash-mini hasn't been pushed to the ubuntu store

Hello!

A couple of months ago we added the packaging to release this project to the snaps store, in #7. But it hasn't been published there yet. We now have a new service that will take care of the continuous delivery for you, so we hope that the process to get into the store will be even easier now.

Please take a look at https://build.snapcraft.io/ and let me know how it goes. We are in beta, so we are looking for comments from devs about their experience in the site.

pura vida.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.