Wallet, RPC, bitcoin-tx, etc updates for confidential transactions

This commit is contained in:
Pieter Wuille 2015-06-08 19:28:47 -07:00 committed by Matt Corallo
parent 74987d30b1
commit 292f923d03
29 changed files with 968 additions and 175 deletions

View file

@ -58,6 +58,17 @@ CPubKey CKey::GetPubKey() const {
return result;
}
CPubKey CKey::ECDH(const CPubKey& pubkey) const {
assert(fValid);
CPubKey result = pubkey;
int clen = result.size();
int ret = secp256k1_point_multiply((unsigned char*)result.begin(), &clen, begin());
assert((int)result.size() == clen);
assert(ret);
assert(result.IsValid());
return result;
}
bool CKey::Sign(const uint256 &hash, std::vector<unsigned char>& vchSig, uint32_t test_case) const {
if (!fValid)
return false;