carrot_core: get_enote_ephemeral_privkey from normal payment proposal
This commit is contained in:
@@ -220,6 +220,12 @@ bool operator==(const CarrotPaymentProposalSelfSendV1 &a, const CarrotPaymentPro
|
||||
0 == memcmp(&a.enote_ephemeral_pubkey, &b.enote_ephemeral_pubkey, sizeof(mx25519_pubkey));
|
||||
}
|
||||
//-------------------------------------------------------------------------------------------------------------------
|
||||
crypto::secret_key get_enote_ephemeral_privkey(const CarrotPaymentProposalV1 &proposal,
|
||||
const input_context_t &input_context)
|
||||
{
|
||||
return get_enote_ephemeral_privkey(proposal.randomness, proposal.destination, input_context);
|
||||
}
|
||||
//-------------------------------------------------------------------------------------------------------------------
|
||||
mx25519_pubkey get_enote_ephemeral_pubkey(const CarrotPaymentProposalV1 &proposal,
|
||||
const input_context_t &input_context)
|
||||
{
|
||||
|
||||
@@ -96,6 +96,14 @@ bool operator==(const CarrotPaymentProposalV1 &a, const CarrotPaymentProposalV1
|
||||
/// equality operators
|
||||
bool operator==(const CarrotPaymentProposalSelfSendV1 &a, const CarrotPaymentProposalSelfSendV1 &b);
|
||||
|
||||
/**
|
||||
* brief: get_enote_ephemeral_privkey - get the proposal's enote ephemeral privkey d_e
|
||||
* param: proposal -
|
||||
* param: input_context -
|
||||
* return: d_e
|
||||
*/
|
||||
crypto::secret_key get_enote_ephemeral_privkey(const CarrotPaymentProposalV1 &proposal,
|
||||
const input_context_t &input_context);
|
||||
/**
|
||||
* brief: get_enote_ephemeral_pubkey - get the proposal's enote ephemeral pubkey D_e
|
||||
* param: proposal -
|
||||
|
||||
Reference in New Issue
Block a user