gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-exchange] 05/13: use new gnunet bling sign structs


From: gnunet
Subject: [taler-exchange] 05/13: use new gnunet bling sign structs
Date: Fri, 22 Dec 2023 16:29:27 +0100

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository exchange.

commit da3bc6a9326b8e0c0c4d6d7af0ec3dc990592f28
Author: Christian Blättler <blatc2@bfh.ch>
AuthorDate: Mon Nov 20 17:35:11 2023 +0100

    use new gnunet bling sign structs
---
 src/include/taler_crypto_lib.h | 123 ++---------------------------------------
 1 file changed, 6 insertions(+), 117 deletions(-)

diff --git a/src/include/taler_crypto_lib.h b/src/include/taler_crypto_lib.h
index f6da2414..d8094434 100644
--- a/src/include/taler_crypto_lib.h
+++ b/src/include/taler_crypto_lib.h
@@ -5882,22 +5882,6 @@ TALER_denomination_group_get_key (
   struct GNUNET_HashCode *key);
 
 
-/**
- * Possible token family key ciphers.
- */
-enum TALER_TokenFamilyCipher
-{
-  /**
-   * RSA based token key.
-   */
-  TALER_TOKEN_FAMILY_CIPHER_RSA = 0,
-
-  /**
-   * Schnorr based token key.
-   */
-  TALER_TOKEN_FAMILY_CIPHER_CS = 1
-};
-
 /**
  * Token family public key.
  */
@@ -5906,23 +5890,7 @@ struct TALER_TokenFamilyPublicKey
   /**
    * Type of the signature.
    */
-  enum TALER_TokenFamilyCipher cipher;
-
-  /**
-   * Details, depending on @e cipher.
-   */
-  union
-  {
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_CS in @a cipher.
-     */
-    struct GNUNET_CRYPTO_CsPublicKey cs;
-
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_RSA in @a cipher.
-     */
-    struct GNUNET_CRYPTO_RsaPublicKey rsa;
-  } key;
+  struct GNUNET_CRYPTO_BlindSignPublicKey public_key;
 };
 
 /**
@@ -5941,26 +5909,7 @@ struct TALER_TokenFamilyPublicKeyHash
  */
 struct TALER_TokenFamilyPrivateKey
 {
-  /**
-   * Type of the signature.
-   */
-  enum TALER_TokenFamilyCipher cipher;
-
-  /**
-   * Details, depending on @e cipher.
-   */
-  union
-  {
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_CS in @a cipher.
-     */
-    struct GNUNET_CRYPTO_CsPrivateKey cs;
-
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_RSA in @a cipher.
-     */
-    struct GNUNET_CRYPTO_RsaPrivateKey rsa;
-  } key;
+  struct GNUNET_CRYPTO_BlindSignPrivateKey private_key;
 };
 
 /**
@@ -5968,26 +5917,7 @@ struct TALER_TokenFamilyPrivateKey
  */
 struct TALER_TokenPublicKey
 {
-  /**
-   * Type of the signature.
-   */
-  enum TALER_TokenFamilyCipher cipher;
-
-  /**
-   * Details, depending on @e cipher.
-   */
-  union
-  {
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_CS in @a cipher.
-     */
-    struct GNUNET_CRYPTO_CsPublicKey cs;
-
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_RSA in @a cipher.
-     */
-    struct GNUNET_CRYPTO_RsaPublicKey rsa;
-  } key;
+  struct GNUNET_CRYPTO_EddsaPublicKey public_key;
 };
 
 /**
@@ -5995,56 +5925,15 @@ struct TALER_TokenPublicKey
  */
 struct TALER_TokenSignature
 {
-  // TODO: Do we need a separate type for this?
-  //       Like TALER_TokenCipher (not token family)
-  /**
-   * Type of the signature.
-   */
-  enum TALER_TokenFamilyCipher cipher;
-
-  /**
-   * Details, depending on @e cipher.
-   */
-  union
-  {
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_CS in @a cipher.
-     */
-    struct GNUNET_CRYPTO_CsSignature cs;
-
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_RSA in @a cipher.
-     */
-    struct GNUNET_CRYPTO_RsaSignature rsa;
-  } signature;
+  struct GNUNET_CRYPTO_EddsaSignature signature;
 };
 
 /**
- * Blind signature for a token.
+ * Blind signature for a token (signed by merchant).
  */
 struct TALER_TokenBlindSignature
 {
-  /**
-   * Type of the signature.
-   */
-  enum TALER_TokenFamilyCipher cipher;
-
-
-  /**
-   * Details, depending on @e cipher.
-   */
-  union
-  {
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_CS in @a cipher.
-     */
-    struct GNUNET_CRYPTO_CsSignature cs;
-
-    /**
-     * If we use #TALER_TOKEN_FAMILY_CIPHER_RSA in @a cipher.
-     */
-    struct GNUNET_CRYPTO_RsaSignature rsa;
-  } signature;
+  struct GNUNET_CRYPTO_BlindedSignature signature;
 };
 
 #endif

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]