[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[taler-docs] branch master updated: [withdraw] cleanup data structures f
From: |
gnunet |
Subject: |
[taler-docs] branch master updated: [withdraw] cleanup data structures for signing |
Date: |
Wed, 15 Jan 2025 12:10:17 +0100 |
This is an automated email from the git hooks/post-receive script.
oec pushed a commit to branch master
in repository taler-docs.
The following commit(s) were added to refs/heads/master by this push:
new c058bddb [withdraw] cleanup data structures for signing
c058bddb is described below
commit c058bddb7b7688459daabf7dc8a1111a513f0840
Author: Özgür Kesim <oec-taler@kesim.org>
AuthorDate: Wed Jan 15 12:09:49 2025 +0100
[withdraw] cleanup data structures for signing
---
core/api-common.rst | 70 ++++++++++++++++++++++-----------------------------
core/api-exchange.rst | 8 +++---
2 files changed, 34 insertions(+), 44 deletions(-)
diff --git a/core/api-common.rst b/core/api-common.rst
index 2dad5ba3..9f1f57a9 100644
--- a/core/api-common.rst
+++ b/core/api-common.rst
@@ -1204,23 +1204,44 @@ within the
struct GNUNET_CRYPTO_EccSignaturePurpose purpose;
struct TALER_ReservePublicKeyP reserve_pub;
/**
- * Total (over all coins) amount to withdraw, including fees.
+ * Amount to withdraw, excluding fees, i.e.
+ * the total sum of the denominations of the coins.
+ * Note that the reserve must have a value of at least amount+fee.
*/
- struct TALER_Amount total_amount_with_fee;
+ struct TALER_Amount amount;
+ /**
+ * Total fee for the withdrawal.
+ * Note that the reserve must have a value of at least amount+fee.
+ */
+ struct TALER_Amount fee;
/**
* This is the running SHA512-hash over all
- * `struct TALER_BlindedCoinHash` values of the coins.
- * If max_age was set in the withdraw request,
- * there will be n*κ many such values.
- * The iteration MUST be first over all coins belonging to
- * kappa index=0, then all coins to kappa index=1 etc.
+ * `TALER_BlindedCoinHashP` values of the coins.
+ * Note that each `TALER_BlindedCoinHashP` itself
+ * captures the hash of the corresponding denomination's
+ * public key.
+ * If max_age was set in the withdraw request, there will be
+ * n*κ many such values. The iteration MUST be first over
+ * all coins belonging to κ index=0, then all coins
+ * to κ index=1 etc:
* h[0][0]…h[0][n-1]h[1][0]…h[1][n-1] … h[κ-1][0]…h[κ-1][n-1]
*/
struct GNUNET_HashCode h_planchets;
/**
- * If max_age is > 0, the mask MUST be non-zero, too
+ * If age restriction applies, maximum age _group_ to commit to,
+ * 0 otherwise.
+ * Note that if age restriction applies, all denominations
+ * for all coins MUST support age restriction.
+ * Also note that this is not an age (in years), but the age group
+ * (an index) according to list of age groups in the configuration
+ * of the exchange. See TALER_get_max_group() how to calculate
+ * the age group to a given age (in years).
+ */
+ uint8_t max_age_group;
+ /**
+ * The age groups as configured for the exchange, represented as a mask.
+ * If max_age_group is > 0, the mask MUST be non-zero, too.
*/
- uint8_t max_age;
struct TALER_AgeMask mask;
};
@@ -1239,37 +1260,6 @@ within the
struct TALER_BlindedCoinHash h_coin_envelope;
};
-.. _TALER_AgeWithdrawRequestPS:
-.. sourcecode:: c
-
- struct TALER_AgeWithdrawRequestPS {
- /**
- * purpose.purpose = TALER_SIGNATURE_WALLET_RESERVE_AGE_WITHDRAW
- */
- struct GNUNET_CRYPTO_EccSignaturePurpose purpose;
- struct TALER_ReservePublicKeyP reserve_pub;
- /**
- * This is the running SHA512-hash over n*kappa
- * `struct TALER_BlindedCoinHash` values
- */
- struct GNUNET_HashCode h_commitment;
- struct TALER_AgeMask mask;
- uint8_t max_age_group;
- };
-
-.. _TALER_AgeWithdrawConfirmationPS:
-
-.. sourcecode:: c
-
- struct TALER_AgeWithdrawConfirmationPS {
- /**
- * purpose.purpose = TALER_SIGNATURE_EXCHANGE_CONFIRM_AGE_WITHDRAW
- */
- struct GNUNET_CRYPTO_EccSignaturePurpose purpose;
- struct GNUNET_HashCode h_commitment;
- uint32_t noreveal_index;
- };
-
.. _taler_depositrequestps:
diff --git a/core/api-exchange.rst b/core/api-exchange.rst
index 7ec4914d..d2609536 100644
--- a/core/api-exchange.rst
+++ b/core/api-exchange.rst
@@ -1646,14 +1646,14 @@ Withdraw
The response is a `WithdrawResponse`.
Note that repeating exactly the same request will again yield the same
response, so if the network goes down during the transaction or before the
- client can commit the coin signature to disk, the coin is not lost.
+ client can commit the coins signature to disk, the coins are not lost.
:http:statuscode:`201 Created`:
The request was successful, and ``max_age`` was set.
The response is a `AgeWithdrawResponse`. The client is expected
to call ``/reveal-withdraw/$ACH`` next.
Note that repeating exactly the same request will again yield the same
response, so if the network goes down during the transaction or before the
- client can commit the coin signature to disk, the coin is not lost.
+ client can commit the coins signature to disk, the coins are not lost.
:http:statuscode:`403 Forbidden`:
A signature is invalid.
This response comes with a standard `ErrorDetail` response.
@@ -1666,7 +1666,7 @@ Withdraw
instead simply wait for up to a day, as the wire transaction might simply
not yet have completed and might be known to the exchange in the near
future.
In this case, the wallet should repeat the exact same request later again
- using exactly the same blinded coin.
+ using exactly the same blinded coins.
:http:statuscode:`409 Conflict`:
One of the following reasons occured:
@@ -1759,7 +1759,7 @@ Withdraw
.. ts:def:: WithdrawResponse
interface WithdrawResponse {
- // Array of blinded signatures over each ``blinded_coin_ev``,
+ // Array of blinded signatures over each ``coin_evs``,
// in the same order as was given in the request.
// The blinded signatures affirm the coin's validity
// after unblinding.
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [taler-docs] branch master updated: [withdraw] cleanup data structures for signing,
gnunet <=