[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[taler-exchange] 03/11: -simplify zero-check for age-commitment hash
From: |
gnunet |
Subject: |
[taler-exchange] 03/11: -simplify zero-check for age-commitment hash |
Date: |
Mon, 13 Mar 2023 00:32:59 +0100 |
This is an automated email from the git hooks/post-receive script.
oec pushed a commit to branch master
in repository exchange.
commit 5608a73c003bbc4547d8e09b24acf94c5af5cb24
Author: Özgür Kesim <oec-taler@kesim.org>
AuthorDate: Tue Mar 7 11:15:24 2023 +0100
-simplify zero-check for age-commitment hash
---
src/include/taler_crypto_lib.h | 9 ++-------
src/util/crypto.c | 5 -----
2 files changed, 2 insertions(+), 12 deletions(-)
diff --git a/src/include/taler_crypto_lib.h b/src/include/taler_crypto_lib.h
index db50efa1..c285a38e 100644
--- a/src/include/taler_crypto_lib.h
+++ b/src/include/taler_crypto_lib.h
@@ -1309,13 +1309,8 @@ struct TALER_AgeAttestation
#endif
};
-
-extern const struct TALER_AgeCommitmentHash TALER_ZeroAgeCommitmentHash;
-#define TALER_AgeCommitmentHash_isNullOrZero(ph) \
- ((NULL == ph) || \
- (0 == memcmp (ph, \
- &TALER_ZeroAgeCommitmentHash, \
- sizeof(struct TALER_AgeCommitmentHash))))
+#define TALER_AgeCommitmentHash_isNullOrZero(ph) ((NULL == ph) || \
+ GNUNET_is_zero (ph))
/**
* @brief Type of public signing keys for verifying blindly signed coins.
diff --git a/src/util/crypto.c b/src/util/crypto.c
index 5cbba813..d164b8a5 100644
--- a/src/util/crypto.c
+++ b/src/util/crypto.c
@@ -26,11 +26,6 @@
#include "taler_util.h"
#include <gcrypt.h>
-/**
- * Used in TALER_AgeCommitmentHash_isNullOrZero for comparison
- */
-const struct TALER_AgeCommitmentHash TALER_ZeroAgeCommitmentHash = {0};
-
/**
* Function called by libgcrypt on serious errors.
* Prints an error message and aborts the process.
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
- [taler-exchange] branch master updated (ce71db2c -> 187ae6f8), gnunet, 2023/03/12
- [taler-exchange] 03/11: -simplify zero-check for age-commitment hash,
gnunet <=
- [taler-exchange] 01/11: WiP: age-withdraw implementation, part 4/n, gnunet, 2023/03/12
- [taler-exchange] 02/11: -minor refactoring in age_withdraw-reveal, gnunet, 2023/03/12
- [taler-exchange] 04/11: WiP: age-withdraw, cut out work up to verify_commitment_and_max_age, gnunet, 2023/03/12
- [taler-exchange] 05/11: simplify hash generation of age commitment, gnunet, 2023/03/12
- [taler-exchange] 08/11: -gana bump, gnunet, 2023/03/12
- [taler-exchange] 10/11: -gana bump, gnunet, 2023/03/12
- [taler-exchange] 06/11: Merge branch 'master' into age-withdraw, gnunet, 2023/03/12
- [taler-exchange] 07/11: WiP: age-withdraw, added TALER_age_restriction_commit_from_base, 6/n, gnunet, 2023/03/12
- [taler-exchange] 09/11: Merge branch 'master' into age-withdraw, gnunet, 2023/03/12
- [taler-exchange] 11/11: WIP: age-withdraw, continue verify_commitment_and_max_age, 7/n, gnunet, 2023/03/12