12 bool is_coinbase,
CKey key) {
19 Stake(std::move(utxo), amount, height, is_coinbase, key.
GetPubKey());
20 const uint256 h = stake.getHash(commitment);
26 return stakes.emplace(std::move(stake), std::move(
sig)).second;
33 proofSignature.fill(0);
35 std::vector<SignedStake> signedStakes;
36 signedStakes.reserve(
stakes.size());
40 signedStakes.push_back(handle.value());
45 std::move(proofSignature));
55 for (
const auto &s :
stakes) {
An encapsulated secp256k1 private key.
bool IsValid() const
Check whether this private key is valid.
CPubKey GetPubKey() const
Compute the public key from a private key.
bool SignSchnorr(const uint256 &hash, SchnorrSig &sig, uint32_t test_case=0) const
Create a Schnorr signature.
An outpoint - a combination of a transaction hash and an index n into its vout.
A writer stream (for serialization) that computes a 256-bit hash.
static RCUPtr make(Args &&...args)
Construct a new object that is owned by the pointer.
bool addUTXO(COutPoint utxo, Amount amount, uint32_t height, bool is_coinbase, CKey key)
std::set< SignedStake, SignedStakeComparator > stakes
ProofId getProofId() const
LimitedProofId getLimitedProofId() const
CScript payoutScriptPubKey
std::array< uint8_t, CPubKey::SCHNORR_SIZE > SchnorrSig
a Schnorr signature
void WriteCompactSize(CSizeComputer &os, uint64_t nSize)