electrum-mnemonic-0.1.1: easy to remember mnemonic for a high-entropy value

Safe HaskellSafe-Inferred

Data.Mnemonic.Electrum

Synopsis

Documentation

encode :: Integer -> StringSource

Generate a mnemonic for an arbitrary Integer using the Electrum word list.

Note about Electrum compatability: When encoding, Electrum only operates on inputs in chunks of 8 hex digits. This encoder is more flexible, supporting input Integers of any size (although they must be positive).

It yields the same result as Electrum's encoder as long as length of the input, when encoded in hex, is an even multiple of 8 digits.

To precisely replicate Electrum, use 'encodeChunks poeticWords' and provide chunks of 8 hex digits at a time.

decode :: String -> Maybe IntegerSource

Decode an electrum mnemonic

encode' :: WordList -> Integer -> StringSource

Generate a mnemonic

encodeChunks :: WordList -> [Int] -> StringSource

Generate a mnemonic using a list of 8 digit hex numbers.