Skip to content
This repository was archived by the owner on Mar 11, 2025. It is now read-only.

Commit 84c37be

Browse files
committed
add comments describing the type CiphertextValidityProofWithCiphertext
1 parent afb9652 commit 84c37be

File tree

1 file changed

+9
-0
lines changed
  • token/confidential-transfer/proof-generation/src

1 file changed

+9
-0
lines changed

token/confidential-transfer/proof-generation/src/lib.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,15 @@ pub fn try_combine_lo_hi_openings(
9292
Some(opening_lo + opening_hi * Scalar::from(two_power))
9393
}
9494

95+
/// A type that wraps a ciphertext validity proof along with two `lo` and `hi`
96+
/// ciphertexts.
97+
///
98+
/// Ciphertext validity proof data contains grouped ElGamal ciphertexts (`lo`
99+
/// and `hi`) and a proof containing the
100+
/// validity of these ciphertexts. Token client-side logic often requires a
101+
/// function to extract specific forms of the grouped ElGamal ciphertexts. This
102+
/// type is a convenience type that contains the proof data and the extracted
103+
/// ciphertexts.
95104
#[derive(Clone, Copy)]
96105
pub struct CiphertextValidityProofWithCiphertext {
97106
pub proof_data: BatchedGroupedCiphertext3HandlesValidityProofData,

0 commit comments

Comments
 (0)