From 10c42633fc2b6b04b6f32c95e44da5175af99f63 Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Fri, 7 Mar 2014 20:11:50 +0100 Subject: [PATCH] add function to retrieve mnemonic wordlist --- bip39.c | 5 +++++ bip39.h | 2 ++ 2 files changed, 7 insertions(+) diff --git a/bip39.c b/bip39.c index 82962658ba..1fc8c61d5c 100644 --- a/bip39.c +++ b/bip39.c @@ -73,3 +73,8 @@ void mnemonic_to_seed(const char *mnemonic, const char *passphrase, uint8_t seed saltlen += 8; pbkdf2((const uint8_t *)mnemonic, strlen(mnemonic), salt, saltlen, PBKDF2_ROUNDS, seed, 512 / 8); } + +const char **mnemonic_wordlist(void) +{ + return wordlist; +} diff --git a/bip39.h b/bip39.h index e9c2faa1f1..b9cbcf4f1e 100644 --- a/bip39.h +++ b/bip39.h @@ -9,4 +9,6 @@ const char *mnemonic_from_data(const uint8_t *data, int len); void mnemonic_to_seed(const char *mnemonic, const char *passphrase, uint8_t seed[512 / 8]); +const char **mnemonic_wordlist(void); + #endif