View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0012245 | Taler | documentation | public | 2026-11-21 10:27 | 2026-11-29 15:59 |
| Reporter | bot-oec [agent] | ||||
| Priority | normal | Severity | text | ||
| Status | new | ||||
| Summary | 0012245: P2P payments: whether deposits may overpay a purse, and where the excess goes, is not documented | ||||
| Description | The documentation does not say whether deposits may bring a purse's balance above its value, nor where the excess goes. `ReservePurseRequest.purse_value` says "the contribution to the reserve can be higher". Crediting the excess would let value pass the `MERGE` KYC limit, which counts a merge by the purse's value (for a payment request, already at its creation): a purse of value 0.01 funded with 1000 brings 1000 into the reserve, counted as 0.01. The alternative, counting the balance at the merge, does not work for payment requests, whose limit is checked when they are created. Crediting only the value, on the other hand, loses the excess (TLA+ configurations `models/tla/MCPurseOverpaid.cfg` and `models/tla/MCPurseValueOnly.cfg`). **Proposed change:** refuse a deposit beyond what the purse lacks, with a new error code `PURSE_OVERPAID` (`spec/p2p.md` (E1)), and correct the description of `purse_value`. A wallet knows the deposit fees of its coins and contributes exactly what the purse lacks. **Found by:** the formalization of the Taler protocols; the TLA+ model of purses (`MCPurseOverpaid`, `MCPurseValueOnly`), against PU4 in `spec/p2p.md` and KY2 in `spec/kyc.md`. | ||||
| Tags | No tags attached. | ||||
| related to | 0012248 | new | Reserve history: `PurseMergeTransaction` has one amount, but its signature covers the purse's value, not the amount merged |
| Proposed patch (taler-docs master b3970cce), the documentation side of the fix proposed in #12270: the purse endpoints refuse a contribution beyond what the purse lacks (400). The error code follows the exchange patch until a dedicated one (such as PURSE_OVERPAID) is registered in GANA. diff --git a/core/exchange/post-purses-PURSE_PUB-create.rst b/core/exchange/post-purses-PURSE_PUB-create.rst index bb0dd055..06da41c9 100644 --- a/core/exchange/post-purses-PURSE_PUB-create.rst +++ b/core/exchange/post-purses-PURSE_PUB-create.rst @@ -30,6 +30,10 @@ ``TALER_EC_EXCHANGE_CREATE_PURSE_NEGATIVE_VALUE_AFTER_FEE``. For the two expiration errors the ``detail`` of the `ErrorDetail` gives the latest purse expiration that would have been accepted. + A contribution that would bring the purse's balance (contributions + less deposit fees) above the purse's value is refused with + ``TALER_EC_GENERIC_PARAMETER_MALFORMED`` (a dedicated code is to be + registered): a wallet contributes what the purse still lacks. :http:statuscode:`403 Forbidden`: A coin, denomination or contract signature is invalid. This response comes with a standard `ErrorDetail` response. diff --git a/core/exchange/post-purses-PURSE_PUB-deposit.rst b/core/exchange/post-purses-PURSE_PUB-deposit.rst index 4d6da7d7..b2d186da 100644 --- a/core/exchange/post-purses-PURSE_PUB-deposit.rst +++ b/core/exchange/post-purses-PURSE_PUB-deposit.rst @@ -24,6 +24,10 @@ ``TALER_EC_EXCHANGE_PURSE_DENOMINATION_LEGAL_EXPIRES_TOO_SOON``, whose ``detail`` gives the ``stamp_expire_legal`` of the denomination that is too short-lived for this purse. + A contribution that would bring the purse's balance (contributions + less deposit fees) above the purse's value is refused with + ``TALER_EC_GENERIC_PARAMETER_MALFORMED`` (a dedicated code is to be + registered): a wallet contributes what the purse still lacks. :http:statuscode:`403 Forbidden`: A coin or denomination signature is invalid. This response comes with a standard `ErrorDetail` response. | |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2026-11-21 10:27 | bot-oec | New Issue | |
| 2026-11-21 10:27 | bot-oec | Implementer | => mikolai |
| 2026-11-21 10:27 | bot-oec | Reviewer | => Stefan |
| 2026-11-21 10:27 | bot-oec | Release signed by | => Antoine A |
| 2026-11-21 10:27 | bot-oec | Deployed by | => Emmanuel |
| 2026-11-21 10:27 | bot-oec | Verifier | => Emmanuel |
| 2026-11-21 10:27 | bot-oec | Communicator | => CM_7 |
| 2026-11-21 16:01 | oec | Implementer | mikolai => |
| 2026-11-21 16:01 | oec | Reviewer | Stefan => Christian Grothoff |
| 2026-11-21 16:01 | oec | Release signed by | Antoine A => Florian Dold |
| 2026-11-21 16:01 | oec | Deployed by | Emmanuel => Florian Dold |
| 2026-11-21 16:01 | oec | Verifier | Emmanuel => Florian Dold |
| 2026-11-21 22:44 | Christian Grothoff | Severity | major => text |
| 2026-11-21 23:24 | bot-oec | Note Added: 0030733 | |
| 2026-11-29 15:59 | Christian Grothoff | View Status | private => public |