Skip to content

Latest commit

 

History

History
18 lines (15 loc) · 859 Bytes

readme.md

File metadata and controls

18 lines (15 loc) · 859 Bytes

PGP word list

Build NuGet

PGP word list and functionality to encode and decode series of PGP words

Usage

// Look up a word for an even byte
PgpWords.ToEvenWord(0xC0); // => "slowdown"
// Look up a byte for an odd word
PgpWords.ToOddByteOrNone("Yucatan"); // => Some(0xFF)

// Convert a byte array to a sequence of pgp words:
PgpWordSequence.ToWords(new byte[] { 0xC0, 0xFF, 0xEE }); // => "slowdown-Yucatan-tycoon"
// Convert a list of words back to bytes:
PgpWordSequence.ToBytesOrNone("slowdown-Yucatan-tycoon"); // => Some([0xC0, 0xFF, 0xEE])