Versions in this module Expand all Collapse all v2 v2.0.4 Apr 20, 2020 Changes in this version + const LightScryptN + const LightScryptP + const MaxSeedBytes + const MinSeedBytes + const OpenwCoinTypePath + const SeedLen + const StandardScryptN + const StandardScryptP + var ErrDecrypt = errors.New("could not decrypt key with given passphrase") + var ErrInvalidDerivedPath = errors.New("Invalid DerivedPath") + var ErrInvalidHDPath = errors.New("Invalid HDPath") + var ErrInvalidSeedLen = fmt.Errorf(..., MinSeedBytes * 8, MaxSeedBytes * 8) + var ErrNoMatch = errors.New("no key for given address or file") + var KeyIDVer = []byte + func EncryptKey(hdkey *HDKey, auth string, scryptN, scryptP int) ([]byte, error) + func GenerateSeed(length uint8) ([]byte, error) + func GetExtendSeed(seed []byte, masterKey string) ([]byte, error) + func KeyFileName(alias, rootId string) string + type HDKey struct + Alias string + KeyID string + RootPath string + func DecryptHDKey(keyjson []byte, auth string) (*HDKey, error) + func NewHDKey(seed []byte, alias, rootPath string) (*HDKey, error) + func StoreHDKey(dir, alias, auth string, scryptN, scryptP int) (*HDKey, string, error) + func StoreHDKeyWithSeed(dir, alias, auth string, seed []byte, scryptN, scryptP int) (*HDKey, string, error) + func (k *HDKey) DerivedKeyWithPath(path string, curveType uint32) (*owkeychain.ExtendedKey, error) + func (k *HDKey) FileName() string + func (k *HDKey) Seed() []byte + type HDKeystore struct + func NewHDKeystore(keydir string, scryptN, scryptP int) *HDKeystore + func (ks *HDKeystore) JoinPath(filename string) string + func (ks *HDKeystore) StoreKey(filename string, key *HDKey, auth string) error + func (ks HDKeystore) GetKey(rootId, filename, auth string) (*HDKey, error)