Documentation ¶
Overview ¶
Copyright 2013-present wemeetagain https://github.com/wemeetagain/go-hdwallet Copyright 2019-present Varunram Ganesh
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( MnPubkeyVByte = []byte{4, 136, 178, 30} // mainnet magic bytes MnPrivkeyVByte = []byte{4, 136, 173, 228} // mainnet magic bytes TestPubkeyVByte = []byte{4, 53, 135, 207} // testnet magic bytes TestPrivkeyVByte = []byte{4, 53, 131, 148} // testnet magic bytes HmacKey = []byte("Bitcoin seed") // HMAC Key )
declare version bytes and HMAC key
Functions ¶
Types ¶
type HDWallet ¶
type HDWallet struct { VersionBytes []byte //4 bytes Depth uint16 //1 byte Fingerprint []byte //4 bytes ChildNumber []byte //4 bytes Chaincode []byte //32 bytes Key []byte //33 bytes }
HDWallet defines the components of a hierarchical deterministic wallet
func (*HDWallet) Child ¶
Child returns the ith child of wallet w. Values of i >= 2^31 signify private key derivation. Attempting private key derivation with a public key will throw an error.
func (*HDWallet) Pub ¶
Pub returns a new wallet which is the public key version of w. If w is a public key, Pub returns a copy of w
Click to show internal directories.
Click to hide internal directories.