From e9eb00e285c80f63cfc08fdd9ea6707d55162e60 Mon Sep 17 00:00:00 2001 From: Özgür Kesim Date: Tue, 1 Mar 2022 17:02:37 +0100 Subject: Refactoring TALER_AgeCommitment Instead of a single struct TALER_AgeCommitment, we now use 1. TALER_AgeCommitment for the age mask and list public keys for age restriciton. 2. TALER_AgeProof for list of private keys for age restriction 3. TALER_AgeCommitmentProof for the aggregation of the former two. Also, we introduce TALER_AgeAttestation as the EDDSA signature to attest a particular age group, along with the function prototypes TALER_age_commitment_attest and TALER_age_commitment_verify. --- src/lib/exchange_api_refresh_common.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/lib/exchange_api_refresh_common.h') diff --git a/src/lib/exchange_api_refresh_common.h b/src/lib/exchange_api_refresh_common.h index 8d7eb282..c06824fe 100644 --- a/src/lib/exchange_api_refresh_common.h +++ b/src/lib/exchange_api_refresh_common.h @@ -53,10 +53,10 @@ struct MeltedCoin struct TALER_Amount original_value; /** - * The original age commitment and its hash. MUST be NULL if no age - * commitment was set. + * The original age commitment, its proof and its hash. MUST be NULL if no + * age commitment was set. */ - const struct TALER_AgeCommitment *age_commitment; + const struct TALER_AgeCommitmentProof *age_commitment_proof; const struct TALER_AgeCommitmentHash *h_age_commitment; /** @@ -100,11 +100,11 @@ struct FreshCoinData struct TALER_CoinSpendPrivateKeyP coin_priv; /** - * Arrays age commitments to be created, one for each cut-and-choose - * dimension. The entries in each list might be NULL and indicate no age - * commitment/restriction on the particular coin. + * Arrays of age commitments and proofs to be created, one for each + * cut-and-choose dimension. The entries in each list might be NULL and + * indicate no age commitment/restriction on the particular coin. */ - struct TALER_AgeCommitment *age_commitment[TALER_CNC_KAPPA]; + struct TALER_AgeCommitmentProof *age_commitment_proof[TALER_CNC_KAPPA]; /** * Blinding key secrets for the coins, depending on the -- cgit v1.2.3