| 473 | } |
| 474 | |
| 475 | static void read_mnemonic(char *mnemonic) { |
| 476 | /* Get words for the mnemonic language */ |
| 477 | struct words *words; |
| 478 | get_words(&words); |
| 479 | |
| 480 | /* Get mnemonic */ |
| 481 | get_mnemonic(mnemonic); |
| 482 | |
| 483 | if (bip39_mnemonic_validate(words, mnemonic) != 0) { |
| 484 | errx(ERROR_USAGE, "Invalid mnemonic: \"%s\"", mnemonic); |
| 485 | } |
| 486 | } |
| 487 | |
| 488 | static int generate_hsm(const char *hsm_secret_path) |
| 489 | { |
no test coverage detected