bip39

package
v0.0.0-...-3ec7072 Latest Latest
Warning

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

Go to latest
Published: Dec 24, 2025 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateSeedFromMnemonic

func CreateSeedFromMnemonic(mnemonic string, passphraseOption ...string) []byte

CreateSeedFromMnemonic creates a seed from a mnemonic.

Types

type MnemonicGenerator

type MnemonicGenerator struct {
	// contains filtered or unexported fields
}

func NewMnemonicGenerator

func NewMnemonicGenerator(language string) (*MnemonicGenerator, error)

NewMnemonicGenerator returns a new MnemonicGenerator for the given language.

func (*MnemonicGenerator) Generate

func (mg *MnemonicGenerator) Generate(strengthOption ...int) (string, error)

Generate Create a new mnemonic using a random generated number as entropy. As defined in BIP39, the entropy must be a multiple of 32 bits, and its size must be between 128 and 256 bits. Therefore the possible values for `strength` are 128, 160, 192, 224 and 256. If not provided, the default entropy length will be set to 128 bits. The return is a list of words that encodes the generated entropy.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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