Merge pull request 'Add support for Wownero' (#2) from wownero into master

Reviewed-on: feather/monero-seed#2
pull/3/head
dsc 4 years ago
commit a4d800fc17

@ -94,8 +94,8 @@ int main(int argc, const char* argv[]) {
else {
std::cout << "Monero 14-word mnemonic seed proof of concept" << std::endl;
std::cout << "Usage: " << std::endl;
std::cout << argv[0] << " --create [--date <yyyy-MM-dd>] [--coin <monero|aeon>]" << std::endl;
std::cout << argv[0] << " --restore \"<14-word seed>\" [--coin <monero|aeon>]" << std::endl;
std::cout << argv[0] << " --create [--date <yyyy-MM-dd>] [--coin <monero|aeon|wownero>]" << std::endl;
std::cout << argv[0] << " --restore \"<14-word seed>\" [--coin <monero|aeon|wownero>]" << std::endl;
}
}
catch (const std::exception & ex) {

@ -59,9 +59,11 @@ constexpr int pbkdf2_iterations = 4096;
static const std::string COIN_MONERO = "monero";
static const std::string COIN_AEON = "aeon";
static const std::string COIN_WOWNERO = "wownero";
constexpr gf_elem monero_flag = gf_elem(0x539);
constexpr gf_elem aeon_flag = gf_elem(0x201);
constexpr gf_elem wownero_flag = gf_elem(0x1a4);
static const char* KDF_PBKDF2 = "PBKDF2-HMAC-SHA256/4096";
@ -105,6 +107,9 @@ static gf_elem get_coin_flag(const std::string& coin) {
else if (coin == COIN_AEON) {
return aeon_flag;
}
else if (coin == COIN_WOWNERO) {
return wownero_flag;
}
else {
THROW_EXCEPTION("invalid coin");
}

Loading…
Cancel
Save