MCPcopy Create free account
hub / github.com/LUX-Core/lux / Debug

Method Debug

src/hdchain.cpp:45–73  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

43}
44
45void CHDChain::Debug(std::string strName) const
46{
47 DEBUG_SECTION(
48 std::cout << __func__ << ": ---" << strName << "---" << std::endl;
49 if (fCrypted) {
50 std::cout << "mnemonic: ***CRYPTED***" << std::endl;
51 std::cout << "mnemonicpassphrase: ***CRYPTED***" << std::endl;
52 std::cout << "seed: ***CRYPTED***" << std::endl;
53 } else {
54 std::cout << "mnemonic: " << std::string(vchMnemonic.begin(), vchMnemonic.end()).c_str() << std::endl;
55 std::cout << "mnemonicpassphrase: " << std::string(vchMnemonicPassphrase.begin(), vchMnemonicPassphrase.end()).c_str() << std::endl;
56 std::cout << "seed: " << HexStr(vchSeed).c_str() << std::endl;
57
58 CExtKey extkey;
59 extkey.SetMaster(&vchSeed[0], vchSeed.size());
60
61 CBitcoinExtKey b58extkey;
62 b58extkey.SetKey(extkey);
63 std::cout << "extended private masterkey: " << b58extkey.ToString().c_str() << std::endl;
64
65 CExtPubKey extpubkey;
66 extpubkey = extkey.Neuter();
67
68 CBitcoinExtPubKey b58extpubkey;
69 b58extpubkey.SetKey(extpubkey);
70 std::cout << "extended public masterkey: " << b58extpubkey.ToString().c_str() << std::endl;
71 }
72 );
73}
74
75bool CHDChain::SetMnemonic(const SecureVector& vchMnemonic, const SecureVector& vchMnemonicPassphrase, bool fUpdateID)
76{

Callers 3

EncryptHDChainMethod · 0.45
DecryptHDChainMethod · 0.45
GenerateNewHDChainMethod · 0.45

Calls 8

HexStrFunction · 0.85
SetMasterMethod · 0.80
NeuterMethod · 0.80
beginMethod · 0.45
endMethod · 0.45
sizeMethod · 0.45
SetKeyMethod · 0.45
ToStringMethod · 0.45

Tested by

no test coverage detected