Commit Graph

55 Commits

Author SHA1 Message Date
Christian Grothoff
94a5359494
-address misc. fixmes 2022-02-12 00:52:19 +01:00
Christian Grothoff
e7aeec04f4
The current recoup API is broken. I guess this is another example where "trivial" API changes turn out to have (multiple!) unexpected consequences.
The current "/recoup" API does not have clear idempotency semantics, as we've discussed on the phone.  This is already bad by itself, as it makes it hard to write down what the API does other than "whatever the implementation does".

However, it actually breaks correctness in this (admittedly kinda contrived, but not impossible) case:

Say that we have a coin A obtained via withdrawal and a coin B obtained via refreshing coin A. Now the denominations of A gets revoked..

The wallet does a recoup of A for EUR:1.

Now the denomination of B also gets revoked.  The wallet recoups B (incidentally also for EUR:1) and now A can be recouped again for EUR:1.  But now the exchange is in a state where it will refuse a legitimate recoup request for A because the detection for an idempotent request kicks in.

This is IMHO bad API design, and the exchange should simply always recoup the maximum amount.

Furthermore, we usually follow the principle of "API calls that take up DB space are paid".  With the current recoup API, I can do many tiny recoup requests which the exchange then has to store, right?

I guess it would not be a big change to remove the "amount" value from the recoup/recoup-refresh request bodies, right?

- Florian
2022-01-11 12:47:35 +01:00
Christian Grothoff
84c9adf5a6
v12: also do not sign over merchant_pub in REFUND signature, centralize logic 2021-12-25 14:58:04 +01:00
Christian Grothoff
87376e02eb
protocol v12 changes (/recoup split, signature changes) plus database sharding plus O(n^2)=>O(n) worst-case complexity reduction on coin balance checks 2021-12-25 13:56:40 +01:00
Christian Grothoff
1acc851deb
-fix recoup ugliness 2021-12-16 20:18:44 +01:00
Christian Grothoff
1a1fafbd43
introducing GNUNET_TIME_Timestamp, recoup now with amounts 2021-12-14 16:04:40 +01:00
Christian Grothoff
a25429cadd
fix #7123 2021-12-11 20:06:15 +01:00
Christian Grothoff
7dcd217b60
-fix balance calculation 2021-12-06 16:37:32 +01:00
Christian Grothoff
6ba9f934c4
-add FIXMEs 2021-12-05 19:23:16 +01:00
Christian Grothoff
52fe9d657b
-fix leaks and compiler warnings 2021-11-19 20:56:53 +01:00
Christian Grothoff
8175fdfa0f
introduce TALER_wallet_deposit_verify 2021-11-06 16:52:14 +01:00
Christian Grothoff
77142acbe8
fix lib/ FTBFS 2021-10-27 13:42:54 +02:00
Christian Grothoff
f7d08e8c2b
-work on FTBFS; 2021-10-27 09:23:13 +02:00
Christian Grothoff
58ea04167c
-fix misc FTBFS 2021-10-27 09:23:13 +02:00
Christian Grothoff
bde1394ee4
implement /kyc-wallet in libtalerexchange 2021-10-17 20:30:06 +02:00
Christian Grothoff
8951abfc50
-finish implemnetation of /kyc-check client library 2021-10-10 17:18:24 +02:00
Christian Grothoff
18541a284b
-allow 0 for refund deadline 2021-08-01 19:18:35 +02:00
Christian Grothoff
42decef957
fix #6939 in exchange 2021-07-24 09:00:35 +02:00
Christian Grothoff
306a08a71c
-rename TALER_amount_get_zero to TALER_amount_set_zero 2021-07-23 13:02:04 +02:00
Christian Grothoff
260e287685
change wire_reference to be uint64_t always; more work on lrbt_callbacks 2021-01-08 23:36:09 +01:00
Christian Grothoff
4e0b510438
extend tests to discover corner cases from #6478, fix code to actually work for those cases 2020-08-13 00:45:02 +02:00
Christian Grothoff
6256bdb15a
implement #6478, but untested as shown by FIXMEs 2020-08-12 20:12:39 +02:00
Christian Grothoff
ddf95c491a
remove unused/unusable coin_sig, return correct coin_pub in recoup-reveal failure context 2020-07-10 22:33:04 +02:00
Christian Grothoff
92ac6dd11a
implement new behavior in exchange httpd and libtalerexchange (for #6416) 2020-07-08 21:24:10 +02:00
Christian Grothoff
8e03498a48
add h_denom to melt signatures (for #6416) 2020-07-08 17:59:05 +02:00
Christian Grothoff
97dfbec081
add h_denom_pub to deposit signatures 2020-07-08 15:46:51 +02:00
Christian Grothoff
54e63f01df
fix #6408: make sure all timestamps are always rounded when they arrive over JSON, or 400 the requester; similarly don't tolerate anything else as client 2020-07-05 21:54:11 +02:00
Christian Grothoff
ed5b98a2c2
GNUNET_free_non_null is gone, use GNUNET_free 2020-07-05 16:58:43 +02:00
Christian Grothoff
4f82885560
towards changing timestamp in deposit confirmation (tests failing) 2020-07-05 16:35:00 +02:00
Christian Grothoff
5ac448738d
fix status code 2020-07-05 16:34:59 +02:00
Christian Grothoff
84a40be0bc
fix #6170 and rest of #6164 2020-04-08 23:52:01 +02:00
Christian Grothoff
50bc862a68
adapt to new GNUnet sign API (#6164) 2020-04-08 18:18:20 +02:00
Christian Grothoff
409d3e8615
check amount compatibility in history logic 2020-04-03 20:47:51 +02:00
Christian Grothoff
5b78fbc631
better types/scoping/indentation 2020-04-01 23:11:56 +02:00
Christian Grothoff
c686fac84b
match updated specification, use CREDIT instead of DEPOSIT for transfers into a reserve 2020-03-30 18:09:47 +02:00
Christian Grothoff
ae9f751a7c
do return fees in history 2020-03-28 20:46:57 +01:00
Christian Grothoff
86f2d65daf
style, indentation and type fixes for lib/ 2020-03-17 17:47:53 +01:00
Christian Grothoff
538ca960a1
bad FIXME, we should not 2020-03-01 12:14:54 +01:00
Christian Grothoff
0a2b049864
big rename fest related to #6067 API renaming 2020-02-29 16:42:10 +01:00
Christian Grothoff
de9ab28ab9
rename fest, make symbols better match new endpoint names 2020-02-27 23:46:53 +01:00
Christian Grothoff
db669ee495
payback -> recoup stranglers 2020-01-18 23:49:37 +01:00
Christian Grothoff
8dbc19758b
fix compiler warnings 2020-01-18 19:16:44 +01:00
Florian Dold
4993863c4c
allow skipping of denom fees check 2020-01-18 13:52:19 +01:00
Christian Grothoff
985db277f1
doxygen fixes 2020-01-17 22:13:40 +01:00
Christian Grothoff
90c411bc19
sort out URL types more nicely 2020-01-17 20:42:24 +01:00
Christian Grothoff
a064ca705e
check currencies match first 2020-01-17 20:20:28 +01:00
Christian Grothoff
23cc4a521f
TODO is already done 2020-01-17 20:02:25 +01:00
Christian Grothoff
11c5283711
prepare API to enable verification of fees in coin history check 2020-01-17 19:54:16 +01:00
Christian Grothoff
33bd1ca2bb
help crappy indenter 2020-01-17 19:36:20 +01:00
Christian Grothoff
385b3e77df
tighten formatting rules 2019-10-31 12:59:50 +01:00