Improve/Fix variable names
ZCProof was too general. pubKeyHash was actually the JoinSplit pubkey itself.
This commit is contained in:
@@ -21,7 +21,7 @@ static constexpr size_t GROTH_PROOF_SIZE = (
|
||||
48); // π_C
|
||||
|
||||
typedef std::array<unsigned char, GROTH_PROOF_SIZE> GrothProof;
|
||||
typedef boost::variant<ZCProof, GrothProof> SproutProof;
|
||||
typedef boost::variant<PHGRProof, GrothProof> SproutProof;
|
||||
|
||||
class JSInput {
|
||||
public:
|
||||
@@ -64,9 +64,10 @@ public:
|
||||
|
||||
static uint256 h_sig(const uint256& randomSeed,
|
||||
const std::array<uint256, NumInputs>& nullifiers,
|
||||
const uint256& pubKeyHash
|
||||
const uint256& joinSplitPubKey
|
||||
);
|
||||
|
||||
// Compute nullifiers, macs, note commitments & encryptions, and SNARK proof
|
||||
virtual SproutProof prove(
|
||||
bool makeGrothProof,
|
||||
const std::array<JSInput, NumInputs>& inputs,
|
||||
@@ -74,7 +75,7 @@ public:
|
||||
std::array<SproutNote, NumOutputs>& out_notes,
|
||||
std::array<ZCNoteEncryption::Ciphertext, NumOutputs>& out_ciphertexts,
|
||||
uint256& out_ephemeralKey,
|
||||
const uint256& pubKeyHash,
|
||||
const uint256& joinSplitPubKey,
|
||||
uint256& out_randomSeed,
|
||||
std::array<uint256, NumInputs>& out_hmacs,
|
||||
std::array<uint256, NumInputs>& out_nullifiers,
|
||||
@@ -90,9 +91,9 @@ public:
|
||||
) = 0;
|
||||
|
||||
virtual bool verify(
|
||||
const ZCProof& proof,
|
||||
const PHGRProof& proof,
|
||||
ProofVerifier& verifier,
|
||||
const uint256& pubKeyHash,
|
||||
const uint256& joinSplitPubKey,
|
||||
const uint256& randomSeed,
|
||||
const std::array<uint256, NumInputs>& hmacs,
|
||||
const std::array<uint256, NumInputs>& nullifiers,
|
||||
|
||||
Reference in New Issue
Block a user