diff options
| author | Wladimir J. van der Laan <[email protected]> | 2014-11-24 14:38:40 +0100 |
|---|---|---|
| committer | Wladimir J. van der Laan <[email protected]> | 2014-11-24 14:39:25 +0100 |
| commit | 6582f323f084a9f758ab2958da69caeb73cd13b4 (patch) | |
| tree | e2521f7a37c3304e9230d7e518985972a6aacf6e /src/rpcdump.cpp | |
| parent | Merge pull request #5309 (diff) | |
| parent | Add key generation/verification to ECC sanity check (diff) | |
| download | discoin-6582f323f084a9f758ab2958da69caeb73cd13b4.tar.xz discoin-6582f323f084a9f758ab2958da69caeb73cd13b4.zip | |
Merge pull request #5224
f321d6b Add key generation/verification to ECC sanity check (Pieter Wuille)
d0c41a7 Add sanity check after key generation (Pieter Wuille)
Diffstat (limited to 'src/rpcdump.cpp')
| -rw-r--r-- | src/rpcdump.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/rpcdump.cpp b/src/rpcdump.cpp index c3ffe38cc..8b95373cf 100644 --- a/src/rpcdump.cpp +++ b/src/rpcdump.cpp @@ -112,6 +112,7 @@ Value importprivkey(const Array& params, bool fHelp) if (!key.IsValid()) throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Private key outside allowed range"); CPubKey pubkey = key.GetPubKey(); + assert(key.VerifyPubKey(pubkey)); CKeyID vchAddress = pubkey.GetID(); { pwalletMain->MarkDirty(); @@ -253,6 +254,7 @@ Value importwallet(const Array& params, bool fHelp) continue; CKey key = vchSecret.GetKey(); CPubKey pubkey = key.GetPubKey(); + assert(key.VerifyPubKey(pubkey)); CKeyID keyid = pubkey.GetID(); if (pwalletMain->HaveKey(keyid)) { LogPrintf("Skipping import of %s (key already present)\n", CBitcoinAddress(keyid).ToString()); |