bip39

package
v0.13.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 29, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package bip39 is the Golang implementation of the BIP39 spec. This code was copied from https://github.com/tyler-smith/go-bip39 which is also MIT licensed.

The official BIP39 spec can be found at https://github.com/bitcoin/bips/blob/master/bip-0039.mediawiki

This code was copied from https://github.com/tyler-smith/go-bip39 which is also MIT licensed.

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrInvalidMnemonic is returned when trying to use a malformed
	// mnemonic.
	ErrInvalidMnemonic = errors.New("invalid mnenomic")

	// ErrChecksumIncorrect is returned when entropy has the incorrect
	// checksum.
	ErrChecksumIncorrect = errors.New("checksum incorrect")
)
View Source
var English = strings.Split(strings.TrimSpace(english), "\n")

English is a slice of mnemonic words taken from the bip39 specification https://raw.githubusercontent.com/bitcoin/bips/master/bip-0039/english.txt

Functions

func EntropyFromMnemonic

func EntropyFromMnemonic(mnemonic string) ([]byte, error)

EntropyFromMnemonic takes a mnemonic generated by this library, and returns the input entropy used to generate the given mnemonic. An error is returned if the given mnemonic is invalid.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL