Documentation ¶
Index ¶
- Constants
- func GetCurveKeyPair_Ed25519(key []byte) ([]byte, []byte, error)
- func MnemonicToSeed(mnemonic string) ([]byte, error)
- type ExtendedKey
- func CKD(curve string, xpar *ExtendedKey, i uint32) (xchd *ExtendedKey, err error)
- func DeriveAccount(curve string, path *bip32path.Bip32Path, xmaster *ExtendedKey) (xchd *ExtendedKey, err error)
- func ExtendKey(xpar *ExtendedKey, key []byte, chainCode []byte) (*ExtendedKey, error)
- func GenerateMasterKey(curve string, seed []byte) (xmaster *ExtendedKey, err error)
Constants ¶
View Source
const ( CURVE_ED25519 string = "ed25519 seed" CURVE_SECP256K1 = "Bitcoin seed" CURVE_NIST256P1 = "Nist256p1 seed" )
Variables ¶
This section is empty.
Functions ¶
func MnemonicToSeed ¶
Types ¶
type ExtendedKey ¶
type ExtendedKey struct { PrivateKey []byte ChainCode []byte CurvePrivateKey []byte CurvePublicKey []byte PublicKey []byte Fingerprint []byte ParentKey *ExtendedKey }
func CKD ¶
func CKD(curve string, xpar *ExtendedKey, i uint32) (xchd *ExtendedKey, err error)
func DeriveAccount ¶
func DeriveAccount(curve string, path *bip32path.Bip32Path, xmaster *ExtendedKey) (xchd *ExtendedKey, err error)
func ExtendKey ¶
func ExtendKey(xpar *ExtendedKey, key []byte, chainCode []byte) (*ExtendedKey, error)
func GenerateMasterKey ¶
func GenerateMasterKey(curve string, seed []byte) (xmaster *ExtendedKey, err error)
Click to show internal directories.
Click to hide internal directories.