rename fest, make symbols better match new endpoint names
This commit is contained in:
parent
cef3b713ac
commit
de9ab28ab9
@ -49,6 +49,7 @@ taler_exchange_httpd_SOURCES = \
|
||||
taler-exchange-httpd.c taler-exchange-httpd.h \
|
||||
taler-exchange-httpd_db.c taler-exchange-httpd_db.h \
|
||||
taler-exchange-httpd_deposit.c taler-exchange-httpd_deposit.h \
|
||||
taler-exchange-httpd_deposits_get.c taler-exchange-httpd_deposits_get.h \
|
||||
taler-exchange-httpd_keystate.c taler-exchange-httpd_keystate.h \
|
||||
taler-exchange-httpd_mhd.c taler-exchange-httpd_mhd.h \
|
||||
taler-exchange-httpd_recoup.c taler-exchange-httpd_recoup.h \
|
||||
@ -56,13 +57,12 @@ taler_exchange_httpd_SOURCES = \
|
||||
taler-exchange-httpd_refresh_melt.c taler-exchange-httpd_refresh_melt.h \
|
||||
taler-exchange-httpd_refresh_reveal.c taler-exchange-httpd_refresh_reveal.h \
|
||||
taler-exchange-httpd_refund.c taler-exchange-httpd_refund.h \
|
||||
taler-exchange-httpd_reserve_status.c taler-exchange-httpd_reserve_status.h \
|
||||
taler-exchange-httpd_reserve_withdraw.c taler-exchange-httpd_reserve_withdraw.h \
|
||||
taler-exchange-httpd_reserves_get.c taler-exchange-httpd_reserves_get.h \
|
||||
taler-exchange-httpd_responses.c taler-exchange-httpd_responses.h \
|
||||
taler-exchange-httpd_terms.c taler-exchange-httpd_terms.h \
|
||||
taler-exchange-httpd_track_transaction.c taler-exchange-httpd_track_transaction.h \
|
||||
taler-exchange-httpd_track_transfer.c taler-exchange-httpd_track_transfer.h \
|
||||
taler-exchange-httpd_transfers_get.c taler-exchange-httpd_transfers_get.h \
|
||||
taler-exchange-httpd_wire.c taler-exchange-httpd_wire.h \
|
||||
taler-exchange-httpd_withdraw.c taler-exchange-httpd_withdraw.h \
|
||||
taler-exchange-httpd_validation.c taler-exchange-httpd_validation.h
|
||||
taler_exchange_httpd_LDADD = \
|
||||
$(LIBGCRYPT_LIBS) \
|
||||
|
@ -30,15 +30,15 @@
|
||||
#include "taler-exchange-httpd_mhd.h"
|
||||
#include "taler-exchange-httpd_deposit.h"
|
||||
#include "taler-exchange-httpd_refund.h"
|
||||
#include "taler-exchange-httpd_reserve_status.h"
|
||||
#include "taler-exchange-httpd_reserve_withdraw.h"
|
||||
#include "taler-exchange-httpd_reserves_get.h"
|
||||
#include "taler-exchange-httpd_withdraw.h"
|
||||
#include "taler-exchange-httpd_recoup.h"
|
||||
#include "taler-exchange-httpd_refresh_link.h"
|
||||
#include "taler-exchange-httpd_refresh_melt.h"
|
||||
#include "taler-exchange-httpd_refresh_reveal.h"
|
||||
#include "taler-exchange-httpd_terms.h"
|
||||
#include "taler-exchange-httpd_track_transfer.h"
|
||||
#include "taler-exchange-httpd_track_transaction.h"
|
||||
#include "taler-exchange-httpd_transfers_get.h"
|
||||
#include "taler-exchange-httpd_deposits_get.h"
|
||||
#include "taler-exchange-httpd_keystate.h"
|
||||
#include "taler-exchange-httpd_wire.h"
|
||||
#include "taler_exchangedb_plugin.h"
|
||||
|
@ -14,7 +14,7 @@
|
||||
TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
/**
|
||||
* @file taler-exchange-httpd_track_transaction.c
|
||||
* @file taler-exchange-httpd_deposits_get.c
|
||||
* @brief Handle wire transfer tracking-related requests
|
||||
* @author Christian Grothoff
|
||||
*/
|
||||
@ -27,7 +27,7 @@
|
||||
#include "taler_mhd_lib.h"
|
||||
#include "taler_signatures.h"
|
||||
#include "taler-exchange-httpd_keystate.h"
|
||||
#include "taler-exchange-httpd_track_transaction.h"
|
||||
#include "taler-exchange-httpd_deposits_get.h"
|
||||
#include "taler-exchange-httpd_responses.h"
|
||||
|
||||
|
||||
@ -419,4 +419,4 @@ TEH_TRACKING_handler_track_transaction (const struct TEH_RequestHandler *rh,
|
||||
}
|
||||
|
||||
|
||||
/* end of taler-exchange-httpd_track_transaction.c */
|
||||
/* end of taler-exchange-httpd_deposits_get.c */
|
@ -14,7 +14,7 @@
|
||||
TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
/**
|
||||
* @file taler-exchange-httpd_track_transaction.h
|
||||
* @file taler-exchange-httpd_deposits_get.h
|
||||
* @brief Handle wire transfer tracking-related requests
|
||||
* @author Christian Grothoff
|
||||
*/
|
@ -14,7 +14,7 @@
|
||||
TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
/**
|
||||
* @file taler-exchange-httpd_reserve_status.c
|
||||
* @file taler-exchange-httpd_reserves_get.c
|
||||
* @brief Handle /reserves/$RESERVE_PUB GET requests
|
||||
* @author Florian Dold
|
||||
* @author Benedikt Mueller
|
||||
@ -25,7 +25,7 @@
|
||||
#include <jansson.h>
|
||||
#include "taler_mhd_lib.h"
|
||||
#include "taler_json_lib.h"
|
||||
#include "taler-exchange-httpd_reserve_status.h"
|
||||
#include "taler-exchange-httpd_reserves_get.h"
|
||||
#include "taler-exchange-httpd_responses.h"
|
||||
#include "taler-exchange-httpd_keystate.h"
|
||||
|
||||
@ -172,4 +172,4 @@ TEH_RESERVE_handler_reserve_status (const struct TEH_RequestHandler *rh,
|
||||
}
|
||||
|
||||
|
||||
/* end of taler-exchange-httpd_reserve_status.c */
|
||||
/* end of taler-exchange-httpd_reserves_get.c */
|
@ -14,7 +14,7 @@
|
||||
TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
/**
|
||||
* @file taler-exchange-httpd_reserve_status.h
|
||||
* @file taler-exchange-httpd_reserves_get.h
|
||||
* @brief Handle /reserves/$RESERVE_PUB GET requests
|
||||
* @author Florian Dold
|
||||
* @author Benedikt Mueller
|
@ -14,7 +14,7 @@
|
||||
TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
/**
|
||||
* @file taler-exchange-httpd_track_transfer.c
|
||||
* @file taler-exchange-httpd_transfers_get.c
|
||||
* @brief Handle wire transfer /track/transfer requests
|
||||
* @author Christian Grothoff
|
||||
*/
|
||||
@ -25,7 +25,7 @@
|
||||
#include <pthread.h>
|
||||
#include "taler_signatures.h"
|
||||
#include "taler-exchange-httpd_keystate.h"
|
||||
#include "taler-exchange-httpd_track_transfer.h"
|
||||
#include "taler-exchange-httpd_transfers_get.h"
|
||||
#include "taler-exchange-httpd_responses.h"
|
||||
#include "taler_json_lib.h"
|
||||
#include "taler_mhd_lib.h"
|
||||
@ -535,4 +535,4 @@ TEH_TRACKING_handler_track_transfer (const struct TEH_RequestHandler *rh,
|
||||
}
|
||||
|
||||
|
||||
/* end of taler-exchange-httpd_track_transfer.c */
|
||||
/* end of taler-exchange-httpd_transfers_get.c */
|
@ -14,7 +14,7 @@
|
||||
TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
/**
|
||||
* @file taler-exchange-httpd_track_transfer.h
|
||||
* @file taler-exchange-httpd_transfers_get.h
|
||||
* @brief Handle wire transfer tracking-related requests
|
||||
* @author Christian Grothoff
|
||||
*/
|
@ -17,7 +17,7 @@
|
||||
see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
/**
|
||||
* @file taler-exchange-httpd_reserve_withdraw.c
|
||||
* @file taler-exchange-httpd_withdraw.c
|
||||
* @brief Handle /reserve/withdraw requests
|
||||
* @author Florian Dold
|
||||
* @author Benedikt Mueller
|
||||
@ -28,7 +28,7 @@
|
||||
#include <jansson.h>
|
||||
#include "taler_json_lib.h"
|
||||
#include "taler_mhd_lib.h"
|
||||
#include "taler-exchange-httpd_reserve_withdraw.h"
|
||||
#include "taler-exchange-httpd_withdraw.h"
|
||||
#include "taler-exchange-httpd_responses.h"
|
||||
#include "taler-exchange-httpd_keystate.h"
|
||||
|
||||
@ -506,4 +506,4 @@ TEH_RESERVE_handler_reserve_withdraw (const struct TEH_RequestHandler *rh,
|
||||
}
|
||||
|
||||
|
||||
/* end of taler-exchange-httpd_reserve_withdraw.c */
|
||||
/* end of taler-exchange-httpd_withdraw.c */
|
@ -14,7 +14,7 @@
|
||||
TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
/**
|
||||
* @file taler-exchange-httpd_reserve_withdraw.h
|
||||
* @file taler-exchange-httpd_withdraw.h
|
||||
* @brief Handle /reserve/withdraw requests
|
||||
* @author Florian Dold
|
||||
* @author Benedikt Mueller
|
@ -1,6 +1,6 @@
|
||||
/*
|
||||
This file is part of TALER
|
||||
Copyright (C) 2014-2018 Taler Systems SA
|
||||
Copyright (C) 2014-2020 Taler Systems SA
|
||||
|
||||
TALER is free software; you can redistribute it and/or modify it under the
|
||||
terms of the GNU Affero General Public License as published by the Free Software
|
||||
@ -493,19 +493,6 @@ TALER_EXCHANGE_test_signing_key (const struct TALER_EXCHANGE_Keys *keys,
|
||||
const struct TALER_ExchangePublicKeyP *pub);
|
||||
|
||||
|
||||
/**
|
||||
* Lookup the given @a pub in @a keys.
|
||||
*
|
||||
* @param keys the exchange's key set
|
||||
* @param pub claimed current online signing key for the exchange
|
||||
* @return NULL if @a pub was not found
|
||||
*/
|
||||
const struct TALER_EXCHANGE_SigningPublicKey *
|
||||
TALER_EXCHANGE_get_signing_key_details (const struct TALER_EXCHANGE_Keys *keys,
|
||||
const struct
|
||||
TALER_ExchangePublicKeyP *pub);
|
||||
|
||||
|
||||
/**
|
||||
* Get exchange's base URL.
|
||||
*
|
||||
@ -574,7 +561,7 @@ TALER_EXCHANGE_get_denomination_key_by_hash (const struct
|
||||
* @return NULL on error (@a exchange_pub not known)
|
||||
*/
|
||||
const struct TALER_EXCHANGE_SigningPublicKey *
|
||||
TALER_EXCHANGE_get_exchange_signing_key_info (const struct
|
||||
TALER_EXCHANGE_get_signing_key_info (const struct
|
||||
TALER_EXCHANGE_Keys *keys,
|
||||
const struct
|
||||
TALER_ExchangePublicKeyP *
|
||||
@ -661,7 +648,7 @@ struct TALER_EXCHANGE_WireAccount
|
||||
* @param accounts list of wire accounts of the exchange, NULL on error
|
||||
*/
|
||||
typedef void
|
||||
(*TALER_EXCHANGE_WireResultCallback) (void *cls,
|
||||
(*TALER_EXCHANGE_WireCallback) (void *cls,
|
||||
unsigned int http_status,
|
||||
enum TALER_ErrorCode ec,
|
||||
unsigned int accounts_len,
|
||||
@ -696,7 +683,7 @@ struct TALER_EXCHANGE_WireHandle;
|
||||
*/
|
||||
struct TALER_EXCHANGE_WireHandle *
|
||||
TALER_EXCHANGE_wire (struct TALER_EXCHANGE_Handle *exchange,
|
||||
TALER_EXCHANGE_WireResultCallback wire_cb,
|
||||
TALER_EXCHANGE_WireCallback wire_cb,
|
||||
void *wire_cb_cls);
|
||||
|
||||
|
||||
@ -833,7 +820,7 @@ struct TALER_EXCHANGE_RefundHandle;
|
||||
* be forwarded to the customer)
|
||||
*/
|
||||
typedef void
|
||||
(*TALER_EXCHANGE_RefundResultCallback) (void *cls,
|
||||
(*TALER_EXCHANGE_RefundCallback) (void *cls,
|
||||
unsigned int http_status,
|
||||
enum TALER_ErrorCode ec,
|
||||
const struct
|
||||
@ -879,7 +866,7 @@ TALER_EXCHANGE_refund (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct TALER_CoinSpendPublicKeyP *coin_pub,
|
||||
uint64_t rtransaction_id,
|
||||
const struct TALER_MerchantPrivateKeyP *merchant_priv,
|
||||
TALER_EXCHANGE_RefundResultCallback cb,
|
||||
TALER_EXCHANGE_RefundCallback cb,
|
||||
void *cb_cls);
|
||||
|
||||
|
||||
@ -923,7 +910,7 @@ TALER_EXCHANGE_refund2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
uint64_t rtransaction_id,
|
||||
const struct TALER_MerchantPublicKeyP *merchant_pub,
|
||||
const struct TALER_MerchantSignatureP *merchant_sig,
|
||||
TALER_EXCHANGE_RefundResultCallback cb,
|
||||
TALER_EXCHANGE_RefundCallback cb,
|
||||
void *cb_cls);
|
||||
|
||||
|
||||
@ -945,7 +932,7 @@ TALER_EXCHANGE_refund_cancel (struct TALER_EXCHANGE_RefundHandle *refund);
|
||||
/**
|
||||
* @brief A /reserve/status Handle
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveStatusHandle;
|
||||
struct TALER_EXCHANGE_ReservesGetHandle;
|
||||
|
||||
|
||||
/**
|
||||
@ -1116,7 +1103,7 @@ struct TALER_EXCHANGE_ReserveHistory
|
||||
* @param history detailed transaction history, NULL on error
|
||||
*/
|
||||
typedef void
|
||||
(*TALER_EXCHANGE_ReserveStatusResultCallback) (void *cls,
|
||||
(*TALER_EXCHANGE_ReservesGetCallback) (void *cls,
|
||||
unsigned int http_status,
|
||||
enum TALER_ErrorCode ec,
|
||||
const json_t *json,
|
||||
@ -1144,11 +1131,11 @@ typedef void
|
||||
* @return a handle for this request; NULL if the inputs are invalid (i.e.
|
||||
* signatures fail to verify). In this case, the callback is not called.
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveStatusHandle *
|
||||
TALER_EXCHANGE_reserve_status (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_ReservesGetHandle *
|
||||
TALER_EXCHANGE_reserves_get (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_ReservePublicKeyP *reserve_pub,
|
||||
TALER_EXCHANGE_ReserveStatusResultCallback cb,
|
||||
TALER_EXCHANGE_ReservesGetCallback cb,
|
||||
void *cb_cls);
|
||||
|
||||
|
||||
@ -1159,8 +1146,8 @@ TALER_EXCHANGE_reserve_status (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* @param rsh the reserve status request handle
|
||||
*/
|
||||
void
|
||||
TALER_EXCHANGE_reserve_status_cancel (struct
|
||||
TALER_EXCHANGE_ReserveStatusHandle *rsh);
|
||||
TALER_EXCHANGE_reserves_get_cancel (struct
|
||||
TALER_EXCHANGE_ReservesGetHandle *rsh);
|
||||
|
||||
|
||||
/* ********************* /reserve/withdraw *********************** */
|
||||
@ -1169,7 +1156,7 @@ TALER_EXCHANGE_reserve_status_cancel (struct
|
||||
/**
|
||||
* @brief A /reserve/withdraw Handle
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle;
|
||||
struct TALER_EXCHANGE_WithdrawHandle;
|
||||
|
||||
|
||||
/**
|
||||
@ -1184,7 +1171,7 @@ struct TALER_EXCHANGE_ReserveWithdrawHandle;
|
||||
* @param full_response full response from the exchange (for logging, in case of errors)
|
||||
*/
|
||||
typedef void
|
||||
(*TALER_EXCHANGE_ReserveWithdrawResultCallback) (void *cls,
|
||||
(*TALER_EXCHANGE_WithdrawCallback) (void *cls,
|
||||
unsigned int http_status,
|
||||
enum TALER_ErrorCode ec,
|
||||
const struct
|
||||
@ -1214,13 +1201,13 @@ typedef void
|
||||
* if the inputs are invalid (i.e. denomination key not with this exchange).
|
||||
* In this case, the callback is not called.
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *
|
||||
TALER_EXCHANGE_reserve_withdraw (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_WithdrawHandle *
|
||||
TALER_EXCHANGE_withdraw (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct TALER_EXCHANGE_DenomPublicKey *pk,
|
||||
const struct
|
||||
TALER_ReservePrivateKeyP *reserve_priv,
|
||||
const struct TALER_PlanchetSecretsP *ps,
|
||||
TALER_EXCHANGE_ReserveWithdrawResultCallback
|
||||
TALER_EXCHANGE_WithdrawCallback
|
||||
res_cb,
|
||||
void *res_cb_cls);
|
||||
|
||||
@ -1247,8 +1234,8 @@ TALER_EXCHANGE_reserve_withdraw (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* if the inputs are invalid (i.e. denomination key not with this exchange).
|
||||
* In this case, the callback is not called.
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *
|
||||
TALER_EXCHANGE_reserve_withdraw2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_WithdrawHandle *
|
||||
TALER_EXCHANGE_withdraw2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_EXCHANGE_DenomPublicKey *pk,
|
||||
const struct
|
||||
@ -1256,7 +1243,7 @@ TALER_EXCHANGE_reserve_withdraw2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_ReservePublicKeyP *reserve_pub,
|
||||
const struct TALER_PlanchetSecretsP *ps,
|
||||
TALER_EXCHANGE_ReserveWithdrawResultCallback
|
||||
TALER_EXCHANGE_WithdrawCallback
|
||||
res_cb,
|
||||
void *res_cb_cls);
|
||||
|
||||
@ -1268,8 +1255,8 @@ TALER_EXCHANGE_reserve_withdraw2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* @param sign the withdraw sign request handle
|
||||
*/
|
||||
void
|
||||
TALER_EXCHANGE_reserve_withdraw_cancel (struct
|
||||
TALER_EXCHANGE_ReserveWithdrawHandle *
|
||||
TALER_EXCHANGE_withdraw_cancel (struct
|
||||
TALER_EXCHANGE_WithdrawHandle *
|
||||
sign);
|
||||
|
||||
|
||||
@ -1551,12 +1538,12 @@ TALER_EXCHANGE_refresh_link_cancel (struct
|
||||
TALER_EXCHANGE_RefreshLinkHandle *rlh);
|
||||
|
||||
|
||||
/* ********************* /track/transfer *********************** */
|
||||
/* ********************* /transfers/$WTID *********************** */
|
||||
|
||||
/**
|
||||
* @brief A /track/transfer Handle
|
||||
* @brief A /transfers/$WTID Handle
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransferHandle;
|
||||
struct TALER_EXCHANGE_TransfersGetHandle;
|
||||
|
||||
|
||||
/**
|
||||
@ -1578,7 +1565,7 @@ struct TALER_EXCHANGE_TrackTransferHandle;
|
||||
* @param details array with details about the combined transactions
|
||||
*/
|
||||
typedef void
|
||||
(*TALER_EXCHANGE_TrackTransferCallback)(void *cls,
|
||||
(*TALER_EXCHANGE_TransfersGetCallback)(void *cls,
|
||||
unsigned int http_status,
|
||||
enum TALER_ErrorCode ec,
|
||||
const struct
|
||||
@ -1604,11 +1591,11 @@ typedef void
|
||||
* @param cb_cls closure for @a cb
|
||||
* @return handle to cancel operation
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransferHandle *
|
||||
TALER_EXCHANGE_track_transfer (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_TransfersGetHandle *
|
||||
TALER_EXCHANGE_transfers_get (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_WireTransferIdentifierRawP *wtid,
|
||||
TALER_EXCHANGE_TrackTransferCallback cb,
|
||||
TALER_EXCHANGE_TransfersGetCallback cb,
|
||||
void *cb_cls);
|
||||
|
||||
|
||||
@ -1619,17 +1606,17 @@ TALER_EXCHANGE_track_transfer (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* @param wdh the wire deposits request handle
|
||||
*/
|
||||
void
|
||||
TALER_EXCHANGE_track_transfer_cancel (struct
|
||||
TALER_EXCHANGE_TrackTransferHandle *wdh);
|
||||
TALER_EXCHANGE_transfers_get_cancel (struct
|
||||
TALER_EXCHANGE_TransfersGetHandle *wdh);
|
||||
|
||||
|
||||
/* ********************* /track/transaction *********************** */
|
||||
/* ********************* GET /deposits/ *********************** */
|
||||
|
||||
|
||||
/**
|
||||
* @brief A /track/transaction Handle
|
||||
* @brief A /deposits/ GET Handle
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransactionHandle;
|
||||
struct TALER_EXCHANGE_DepositGetHandle;
|
||||
|
||||
|
||||
/**
|
||||
@ -1647,7 +1634,7 @@ struct TALER_EXCHANGE_TrackTransactionHandle;
|
||||
* @param coin_contribution contribution to the total amount by this coin (can be NULL)
|
||||
*/
|
||||
typedef void
|
||||
(*TALER_EXCHANGE_TrackTransactionCallback)(void *cls,
|
||||
(*TALER_EXCHANGE_DepositGetCallback)(void *cls,
|
||||
unsigned int http_status,
|
||||
enum TALER_ErrorCode ec,
|
||||
const struct
|
||||
@ -1676,8 +1663,8 @@ typedef void
|
||||
* @param cb_cls closure for @a cb
|
||||
* @return handle to abort request
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransactionHandle *
|
||||
TALER_EXCHANGE_track_transaction (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_DepositGetHandle *
|
||||
TALER_EXCHANGE_deposits_get (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_MerchantPrivateKeyP *merchant_priv,
|
||||
const struct GNUNET_HashCode *h_wire,
|
||||
@ -1685,7 +1672,7 @@ TALER_EXCHANGE_track_transaction (struct TALER_EXCHANGE_Handle *exchange,
|
||||
GNUNET_HashCode *h_contract_terms,
|
||||
const struct
|
||||
TALER_CoinSpendPublicKeyP *coin_pub,
|
||||
TALER_EXCHANGE_TrackTransactionCallback cb,
|
||||
TALER_EXCHANGE_DepositGetCallback cb,
|
||||
void *cb_cls);
|
||||
|
||||
|
||||
@ -1696,8 +1683,8 @@ TALER_EXCHANGE_track_transaction (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* @param dwh the wire deposits request handle
|
||||
*/
|
||||
void
|
||||
TALER_EXCHANGE_track_transaction_cancel (struct
|
||||
TALER_EXCHANGE_TrackTransactionHandle *
|
||||
TALER_EXCHANGE_deposits_get_cancel (struct
|
||||
TALER_EXCHANGE_DepositGetHandle *
|
||||
dwh);
|
||||
|
||||
|
||||
|
@ -382,7 +382,7 @@ TALER_EXCHANGE_verify_coin_history (const struct
|
||||
* @return NULL on error (@a exchange_pub not known)
|
||||
*/
|
||||
const struct TALER_EXCHANGE_SigningPublicKey *
|
||||
TALER_EXCHANGE_get_exchange_signing_key_info (const struct
|
||||
TALER_EXCHANGE_get_signing_key_info (const struct
|
||||
TALER_EXCHANGE_Keys *keys,
|
||||
const struct
|
||||
TALER_ExchangePublicKeyP *
|
||||
@ -390,9 +390,9 @@ TALER_EXCHANGE_get_exchange_signing_key_info (const struct
|
||||
{
|
||||
for (unsigned int i = 0; i<keys->num_sign_keys; i++)
|
||||
{
|
||||
const struct TALER_EXCHANGE_SigningPublicKey *spk;
|
||||
const struct TALER_EXCHANGE_SigningPublicKey *spk
|
||||
= &keys->sign_keys[i];
|
||||
|
||||
spk = &keys->sign_keys[i];
|
||||
if (0 == GNUNET_memcmp (exchange_pub,
|
||||
&spk->key))
|
||||
return spk;
|
||||
|
@ -146,7 +146,7 @@ auditor_cb (void *cls,
|
||||
"Will provide deposit confirmation to auditor `%s'\n",
|
||||
TALER_B2S (auditor_pub));
|
||||
key_state = TALER_EXCHANGE_get_keys (dh->exchange);
|
||||
spk = TALER_EXCHANGE_get_signing_key_details (key_state,
|
||||
spk = TALER_EXCHANGE_get_signing_key_info (key_state,
|
||||
&dh->exchange_pub);
|
||||
GNUNET_assert (NULL != spk);
|
||||
TALER_amount_ntoh (&amount_without_fee,
|
||||
|
@ -2037,30 +2037,6 @@ TALER_EXCHANGE_disconnect (struct TALER_EXCHANGE_Handle *exchange)
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Lookup the given @a pub in @a keys.
|
||||
*
|
||||
* @param keys the exchange's key set
|
||||
* @param pub claimed current online signing key for the exchange
|
||||
* @return NULL if @a pub was not found
|
||||
*/
|
||||
const struct TALER_EXCHANGE_SigningPublicKey *
|
||||
TALER_EXCHANGE_get_signing_key_details (const struct TALER_EXCHANGE_Keys *keys,
|
||||
const struct
|
||||
TALER_ExchangePublicKeyP *pub)
|
||||
{
|
||||
for (unsigned int i = 0; i<keys->num_sign_keys; i++)
|
||||
{
|
||||
struct TALER_EXCHANGE_SigningPublicKey *spk = &keys->sign_keys[i];
|
||||
|
||||
if (0 == GNUNET_memcmp (pub,
|
||||
&spk->key))
|
||||
return spk;
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Test if the given @a pub is a the current signing key from the exchange
|
||||
* according to @a keys.
|
||||
|
@ -62,7 +62,7 @@ struct TALER_EXCHANGE_RefundHandle
|
||||
/**
|
||||
* Function to call with the result.
|
||||
*/
|
||||
TALER_EXCHANGE_RefundResultCallback cb;
|
||||
TALER_EXCHANGE_RefundCallback cb;
|
||||
|
||||
/**
|
||||
* Closure for @a cb.
|
||||
@ -250,7 +250,7 @@ TALER_EXCHANGE_refund (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct TALER_CoinSpendPublicKeyP *coin_pub,
|
||||
uint64_t rtransaction_id,
|
||||
const struct TALER_MerchantPrivateKeyP *merchant_priv,
|
||||
TALER_EXCHANGE_RefundResultCallback cb,
|
||||
TALER_EXCHANGE_RefundCallback cb,
|
||||
void *cb_cls)
|
||||
{
|
||||
struct TALER_RefundRequestPS rr;
|
||||
@ -326,7 +326,7 @@ TALER_EXCHANGE_refund2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
uint64_t rtransaction_id,
|
||||
const struct TALER_MerchantPublicKeyP *merchant_pub,
|
||||
const struct TALER_MerchantSignatureP *merchant_sig,
|
||||
TALER_EXCHANGE_RefundResultCallback cb,
|
||||
TALER_EXCHANGE_RefundCallback cb,
|
||||
void *cb_cls)
|
||||
{
|
||||
struct TALER_EXCHANGE_RefundHandle *rh;
|
||||
|
@ -37,7 +37,7 @@
|
||||
/**
|
||||
* @brief A Withdraw Status Handle
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveStatusHandle
|
||||
struct TALER_EXCHANGE_ReservesGetHandle
|
||||
{
|
||||
|
||||
/**
|
||||
@ -58,7 +58,7 @@ struct TALER_EXCHANGE_ReserveStatusHandle
|
||||
/**
|
||||
* Function to call with the result.
|
||||
*/
|
||||
TALER_EXCHANGE_ReserveStatusResultCallback cb;
|
||||
TALER_EXCHANGE_ReservesGetCallback cb;
|
||||
|
||||
/**
|
||||
* Public key of the reserve we are querying.
|
||||
@ -495,7 +495,7 @@ free_rhistory (struct TALER_EXCHANGE_ReserveHistory *rhistory,
|
||||
* @return #GNUNET_OK on success
|
||||
*/
|
||||
static int
|
||||
handle_reserve_status_ok (struct TALER_EXCHANGE_ReserveStatusHandle *rsh,
|
||||
handle_reserve_status_ok (struct TALER_EXCHANGE_ReservesGetHandle *rsh,
|
||||
const json_t *j)
|
||||
{
|
||||
json_t *history;
|
||||
@ -575,7 +575,7 @@ handle_reserve_status_ok (struct TALER_EXCHANGE_ReserveStatusHandle *rsh,
|
||||
* Function called when we're done processing the
|
||||
* HTTP /reserve/status request.
|
||||
*
|
||||
* @param cls the `struct TALER_EXCHANGE_ReserveStatusHandle`
|
||||
* @param cls the `struct TALER_EXCHANGE_ReservesGetHandle`
|
||||
* @param response_code HTTP response code, 0 on error
|
||||
* @param response parsed JSON result, NULL on error
|
||||
*/
|
||||
@ -584,7 +584,7 @@ handle_reserve_status_finished (void *cls,
|
||||
long response_code,
|
||||
const void *response)
|
||||
{
|
||||
struct TALER_EXCHANGE_ReserveStatusHandle *rsh = cls;
|
||||
struct TALER_EXCHANGE_ReservesGetHandle *rsh = cls;
|
||||
const json_t *j = response;
|
||||
|
||||
rsh->job = NULL;
|
||||
@ -629,7 +629,7 @@ handle_reserve_status_finished (void *cls,
|
||||
0, NULL);
|
||||
rsh->cb = NULL;
|
||||
}
|
||||
TALER_EXCHANGE_reserve_status_cancel (rsh);
|
||||
TALER_EXCHANGE_reserves_get_cancel (rsh);
|
||||
}
|
||||
|
||||
|
||||
@ -649,14 +649,14 @@ handle_reserve_status_finished (void *cls,
|
||||
* @return a handle for this request; NULL if the inputs are invalid (i.e.
|
||||
* signatures fail to verify). In this case, the callback is not called.
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveStatusHandle *
|
||||
TALER_EXCHANGE_reserve_status (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_ReservesGetHandle *
|
||||
TALER_EXCHANGE_reserves_get (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_ReservePublicKeyP *reserve_pub,
|
||||
TALER_EXCHANGE_ReserveStatusResultCallback cb,
|
||||
TALER_EXCHANGE_ReservesGetCallback cb,
|
||||
void *cb_cls)
|
||||
{
|
||||
struct TALER_EXCHANGE_ReserveStatusHandle *rsh;
|
||||
struct TALER_EXCHANGE_ReservesGetHandle *rsh;
|
||||
struct GNUNET_CURL_Context *ctx;
|
||||
CURL *eh;
|
||||
char arg_str[sizeof (struct TALER_ReservePublicKeyP) * 2 + 16];
|
||||
@ -682,7 +682,7 @@ TALER_EXCHANGE_reserve_status (struct TALER_EXCHANGE_Handle *exchange,
|
||||
"/reserves/%s",
|
||||
pub_str);
|
||||
}
|
||||
rsh = GNUNET_new (struct TALER_EXCHANGE_ReserveStatusHandle);
|
||||
rsh = GNUNET_new (struct TALER_EXCHANGE_ReservesGetHandle);
|
||||
rsh->exchange = exchange;
|
||||
rsh->cb = cb;
|
||||
rsh->cb_cls = cb_cls;
|
||||
@ -707,8 +707,8 @@ TALER_EXCHANGE_reserve_status (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* @param rsh the reserve status request handle
|
||||
*/
|
||||
void
|
||||
TALER_EXCHANGE_reserve_status_cancel (struct
|
||||
TALER_EXCHANGE_ReserveStatusHandle *rsh)
|
||||
TALER_EXCHANGE_reserves_get_cancel (struct
|
||||
TALER_EXCHANGE_ReservesGetHandle *rsh)
|
||||
{
|
||||
if (NULL != rsh->job)
|
||||
{
|
||||
@ -725,7 +725,7 @@ TALER_EXCHANGE_reserve_status_cancel (struct
|
||||
/**
|
||||
* @brief A Withdraw Sign Handle
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle
|
||||
struct TALER_EXCHANGE_WithdrawHandle
|
||||
{
|
||||
|
||||
/**
|
||||
@ -752,7 +752,7 @@ struct TALER_EXCHANGE_ReserveWithdrawHandle
|
||||
/**
|
||||
* Function to call with the result.
|
||||
*/
|
||||
TALER_EXCHANGE_ReserveWithdrawResultCallback cb;
|
||||
TALER_EXCHANGE_WithdrawCallback cb;
|
||||
|
||||
/**
|
||||
* Secrets of the planchet.
|
||||
@ -796,7 +796,7 @@ struct TALER_EXCHANGE_ReserveWithdrawHandle
|
||||
* @return #GNUNET_OK on success, #GNUNET_SYSERR on errors
|
||||
*/
|
||||
static int
|
||||
reserve_withdraw_ok (struct TALER_EXCHANGE_ReserveWithdrawHandle *wsh,
|
||||
reserve_withdraw_ok (struct TALER_EXCHANGE_WithdrawHandle *wsh,
|
||||
const json_t *json)
|
||||
{
|
||||
struct GNUNET_CRYPTO_RsaSignature *blind_sig;
|
||||
@ -855,7 +855,7 @@ reserve_withdraw_ok (struct TALER_EXCHANGE_ReserveWithdrawHandle *wsh,
|
||||
*/
|
||||
static int
|
||||
reserve_withdraw_payment_required (struct
|
||||
TALER_EXCHANGE_ReserveWithdrawHandle *wsh,
|
||||
TALER_EXCHANGE_WithdrawHandle *wsh,
|
||||
const json_t *json)
|
||||
{
|
||||
struct TALER_Amount balance;
|
||||
@ -956,7 +956,7 @@ reserve_withdraw_payment_required (struct
|
||||
* Function called when we're done processing the
|
||||
* HTTP /reserves/$RESERVE_PUB/withdraw request.
|
||||
*
|
||||
* @param cls the `struct TALER_EXCHANGE_ReserveWithdrawHandle`
|
||||
* @param cls the `struct TALER_EXCHANGE_WithdrawHandle`
|
||||
* @param response_code HTTP response code, 0 on error
|
||||
* @param response parsed JSON result, NULL on error
|
||||
*/
|
||||
@ -965,7 +965,7 @@ handle_reserve_withdraw_finished (void *cls,
|
||||
long response_code,
|
||||
const void *response)
|
||||
{
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *wsh = cls;
|
||||
struct TALER_EXCHANGE_WithdrawHandle *wsh = cls;
|
||||
const json_t *j = response;
|
||||
|
||||
wsh->job = NULL;
|
||||
@ -1031,13 +1031,13 @@ handle_reserve_withdraw_finished (void *cls,
|
||||
j);
|
||||
wsh->cb = NULL;
|
||||
}
|
||||
TALER_EXCHANGE_reserve_withdraw_cancel (wsh);
|
||||
TALER_EXCHANGE_withdraw_cancel (wsh);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Helper function for #TALER_EXCHANGE_reserve_withdraw2() and
|
||||
* #TALER_EXCHANGE_reserve_withdraw().
|
||||
* Helper function for #TALER_EXCHANGE_withdraw2() and
|
||||
* #TALER_EXCHANGE_withdraw().
|
||||
*
|
||||
* @param exchange the exchange handle; the exchange must be ready to operate
|
||||
* @param pk kind of coin to create
|
||||
@ -1052,17 +1052,17 @@ handle_reserve_withdraw_finished (void *cls,
|
||||
* if the inputs are invalid (i.e. denomination key not with this exchange).
|
||||
* In this case, the callback is not called.
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *
|
||||
struct TALER_EXCHANGE_WithdrawHandle *
|
||||
reserve_withdraw_internal (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct TALER_EXCHANGE_DenomPublicKey *pk,
|
||||
const struct TALER_ReserveSignatureP *reserve_sig,
|
||||
const struct TALER_ReservePublicKeyP *reserve_pub,
|
||||
const struct TALER_PlanchetSecretsP *ps,
|
||||
const struct TALER_PlanchetDetail *pd,
|
||||
TALER_EXCHANGE_ReserveWithdrawResultCallback res_cb,
|
||||
TALER_EXCHANGE_WithdrawCallback res_cb,
|
||||
void *res_cb_cls)
|
||||
{
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *wsh;
|
||||
struct TALER_EXCHANGE_WithdrawHandle *wsh;
|
||||
struct GNUNET_CURL_Context *ctx;
|
||||
json_t *withdraw_obj;
|
||||
CURL *eh;
|
||||
@ -1084,7 +1084,7 @@ reserve_withdraw_internal (struct TALER_EXCHANGE_Handle *exchange,
|
||||
"/reserves/%s/withdraw",
|
||||
pub_str);
|
||||
}
|
||||
wsh = GNUNET_new (struct TALER_EXCHANGE_ReserveWithdrawHandle);
|
||||
wsh = GNUNET_new (struct TALER_EXCHANGE_WithdrawHandle);
|
||||
wsh->exchange = exchange;
|
||||
wsh->cb = res_cb;
|
||||
wsh->cb_cls = res_cb_cls;
|
||||
@ -1159,13 +1159,13 @@ reserve_withdraw_internal (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* if the inputs are invalid (i.e. denomination key not with this exchange).
|
||||
* In this case, the callback is not called.
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *
|
||||
TALER_EXCHANGE_reserve_withdraw (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_WithdrawHandle *
|
||||
TALER_EXCHANGE_withdraw (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct TALER_EXCHANGE_DenomPublicKey *pk,
|
||||
const struct
|
||||
TALER_ReservePrivateKeyP *reserve_priv,
|
||||
const struct TALER_PlanchetSecretsP *ps,
|
||||
TALER_EXCHANGE_ReserveWithdrawResultCallback
|
||||
TALER_EXCHANGE_WithdrawCallback
|
||||
res_cb,
|
||||
void *res_cb_cls)
|
||||
{
|
||||
@ -1173,7 +1173,7 @@ TALER_EXCHANGE_reserve_withdraw (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_ReserveSignatureP reserve_sig;
|
||||
struct TALER_WithdrawRequestPS req;
|
||||
struct TALER_PlanchetDetail pd;
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *wsh;
|
||||
struct TALER_EXCHANGE_WithdrawHandle *wsh;
|
||||
|
||||
GNUNET_CRYPTO_eddsa_key_get_public (&reserve_priv->eddsa_priv,
|
||||
&req.reserve_pub.eddsa_pub);
|
||||
@ -1243,8 +1243,8 @@ TALER_EXCHANGE_reserve_withdraw (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* if the inputs are invalid (i.e. denomination key not with this exchange).
|
||||
* In this case, the callback is not called.
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *
|
||||
TALER_EXCHANGE_reserve_withdraw2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_WithdrawHandle *
|
||||
TALER_EXCHANGE_withdraw2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_EXCHANGE_DenomPublicKey *pk,
|
||||
const struct
|
||||
@ -1252,11 +1252,11 @@ TALER_EXCHANGE_reserve_withdraw2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_ReservePublicKeyP *reserve_pub,
|
||||
const struct TALER_PlanchetSecretsP *ps,
|
||||
TALER_EXCHANGE_ReserveWithdrawResultCallback
|
||||
TALER_EXCHANGE_WithdrawCallback
|
||||
res_cb,
|
||||
void *res_cb_cls)
|
||||
{
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *wsh;
|
||||
struct TALER_EXCHANGE_WithdrawHandle *wsh;
|
||||
struct TALER_PlanchetDetail pd;
|
||||
|
||||
if (GNUNET_OK !=
|
||||
@ -1287,8 +1287,8 @@ TALER_EXCHANGE_reserve_withdraw2 (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* @param sign the withdraw sign request handle
|
||||
*/
|
||||
void
|
||||
TALER_EXCHANGE_reserve_withdraw_cancel (struct
|
||||
TALER_EXCHANGE_ReserveWithdrawHandle *
|
||||
TALER_EXCHANGE_withdraw_cancel (struct
|
||||
TALER_EXCHANGE_WithdrawHandle *
|
||||
sign)
|
||||
{
|
||||
if (NULL != sign->job)
|
||||
|
@ -35,7 +35,7 @@
|
||||
/**
|
||||
* @brief A Deposit Wtid Handle
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransactionHandle
|
||||
struct TALER_EXCHANGE_DepositGetHandle
|
||||
{
|
||||
|
||||
/**
|
||||
@ -62,7 +62,7 @@ struct TALER_EXCHANGE_TrackTransactionHandle
|
||||
/**
|
||||
* Function to call with the result.
|
||||
*/
|
||||
TALER_EXCHANGE_TrackTransactionCallback cb;
|
||||
TALER_EXCHANGE_DepositGetCallback cb;
|
||||
|
||||
/**
|
||||
* Closure for @a cb.
|
||||
@ -89,7 +89,7 @@ struct TALER_EXCHANGE_TrackTransactionHandle
|
||||
*/
|
||||
static int
|
||||
verify_deposit_wtid_signature_ok (const struct
|
||||
TALER_EXCHANGE_TrackTransactionHandle *dwh,
|
||||
TALER_EXCHANGE_DepositGetHandle *dwh,
|
||||
const json_t *json,
|
||||
struct TALER_ExchangePublicKeyP *exchange_pub)
|
||||
{
|
||||
@ -134,7 +134,7 @@ verify_deposit_wtid_signature_ok (const struct
|
||||
* Function called when we're done processing the
|
||||
* HTTP /track/transaction request.
|
||||
*
|
||||
* @param cls the `struct TALER_EXCHANGE_TrackTransactionHandle`
|
||||
* @param cls the `struct TALER_EXCHANGE_DepositGetHandle`
|
||||
* @param response_code HTTP response code, 0 on error
|
||||
* @param response parsed JSON result, NULL on error
|
||||
*/
|
||||
@ -143,7 +143,7 @@ handle_deposit_wtid_finished (void *cls,
|
||||
long response_code,
|
||||
const void *response)
|
||||
{
|
||||
struct TALER_EXCHANGE_TrackTransactionHandle *dwh = cls;
|
||||
struct TALER_EXCHANGE_DepositGetHandle *dwh = cls;
|
||||
const struct TALER_WireTransferIdentifierRawP *wtid = NULL;
|
||||
struct GNUNET_TIME_Absolute execution_time = GNUNET_TIME_UNIT_FOREVER_ABS;
|
||||
const struct TALER_Amount *coin_contribution = NULL;
|
||||
@ -247,7 +247,7 @@ handle_deposit_wtid_finished (void *cls,
|
||||
wtid,
|
||||
execution_time,
|
||||
coin_contribution);
|
||||
TALER_EXCHANGE_track_transaction_cancel (dwh);
|
||||
TALER_EXCHANGE_deposits_get_cancel (dwh);
|
||||
}
|
||||
|
||||
|
||||
@ -264,8 +264,8 @@ handle_deposit_wtid_finished (void *cls,
|
||||
* @param cb_cls closure for @a cb
|
||||
* @return handle to abort request
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransactionHandle *
|
||||
TALER_EXCHANGE_track_transaction (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_DepositGetHandle *
|
||||
TALER_EXCHANGE_deposits_get (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_MerchantPrivateKeyP *merchant_priv,
|
||||
const struct GNUNET_HashCode *h_wire,
|
||||
@ -273,12 +273,12 @@ TALER_EXCHANGE_track_transaction (struct TALER_EXCHANGE_Handle *exchange,
|
||||
GNUNET_HashCode *h_contract_terms,
|
||||
const struct
|
||||
TALER_CoinSpendPublicKeyP *coin_pub,
|
||||
TALER_EXCHANGE_TrackTransactionCallback cb,
|
||||
TALER_EXCHANGE_DepositGetCallback cb,
|
||||
void *cb_cls)
|
||||
{
|
||||
struct TALER_DepositTrackPS dtp;
|
||||
struct TALER_MerchantSignatureP merchant_sig;
|
||||
struct TALER_EXCHANGE_TrackTransactionHandle *dwh;
|
||||
struct TALER_EXCHANGE_DepositGetHandle *dwh;
|
||||
struct GNUNET_CURL_Context *ctx;
|
||||
CURL *eh;
|
||||
char arg_str[(sizeof (struct TALER_CoinSpendPublicKeyP)
|
||||
@ -354,7 +354,7 @@ TALER_EXCHANGE_track_transaction (struct TALER_EXCHANGE_Handle *exchange,
|
||||
msig_str);
|
||||
}
|
||||
|
||||
dwh = GNUNET_new (struct TALER_EXCHANGE_TrackTransactionHandle);
|
||||
dwh = GNUNET_new (struct TALER_EXCHANGE_DepositGetHandle);
|
||||
dwh->exchange = exchange;
|
||||
dwh->cb = cb;
|
||||
dwh->cb_cls = cb_cls;
|
||||
@ -384,8 +384,8 @@ TALER_EXCHANGE_track_transaction (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* @param dwh the wire deposits request handle
|
||||
*/
|
||||
void
|
||||
TALER_EXCHANGE_track_transaction_cancel (struct
|
||||
TALER_EXCHANGE_TrackTransactionHandle *
|
||||
TALER_EXCHANGE_deposits_get_cancel (struct
|
||||
TALER_EXCHANGE_DepositGetHandle *
|
||||
dwh)
|
||||
{
|
||||
if (NULL != dwh->job)
|
||||
|
@ -34,7 +34,7 @@
|
||||
/**
|
||||
* @brief A /track/transfer Handle
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransferHandle
|
||||
struct TALER_EXCHANGE_TransfersGetHandle
|
||||
{
|
||||
|
||||
/**
|
||||
@ -55,7 +55,7 @@ struct TALER_EXCHANGE_TrackTransferHandle
|
||||
/**
|
||||
* Function to call with the result.
|
||||
*/
|
||||
TALER_EXCHANGE_TrackTransferCallback cb;
|
||||
TALER_EXCHANGE_TransfersGetCallback cb;
|
||||
|
||||
/**
|
||||
* Closure for @a cb.
|
||||
@ -81,7 +81,7 @@ struct TALER_EXCHANGE_TrackTransferHandle
|
||||
*/
|
||||
static int
|
||||
check_track_transfer_response_ok (struct
|
||||
TALER_EXCHANGE_TrackTransferHandle *wdh,
|
||||
TALER_EXCHANGE_TransfersGetHandle *wdh,
|
||||
const json_t *json)
|
||||
{
|
||||
json_t *details_j;
|
||||
@ -241,7 +241,7 @@ check_track_transfer_response_ok (struct
|
||||
details);
|
||||
}
|
||||
GNUNET_JSON_parse_free (spec);
|
||||
TALER_EXCHANGE_track_transfer_cancel (wdh);
|
||||
TALER_EXCHANGE_transfers_get_cancel (wdh);
|
||||
return GNUNET_OK;
|
||||
}
|
||||
|
||||
@ -250,7 +250,7 @@ check_track_transfer_response_ok (struct
|
||||
* Function called when we're done processing the
|
||||
* HTTP /track/transfer request.
|
||||
*
|
||||
* @param cls the `struct TALER_EXCHANGE_TrackTransferHandle`
|
||||
* @param cls the `struct TALER_EXCHANGE_TransfersGetHandle`
|
||||
* @param response_code HTTP response code, 0 on error
|
||||
* @param response parsed JSON result, NULL on error
|
||||
*/
|
||||
@ -259,7 +259,7 @@ handle_track_transfer_finished (void *cls,
|
||||
long response_code,
|
||||
const void *response)
|
||||
{
|
||||
struct TALER_EXCHANGE_TrackTransferHandle *wdh = cls;
|
||||
struct TALER_EXCHANGE_TransfersGetHandle *wdh = cls;
|
||||
const json_t *j = response;
|
||||
|
||||
wdh->job = NULL;
|
||||
@ -311,7 +311,7 @@ handle_track_transfer_finished (void *cls,
|
||||
NULL,
|
||||
NULL,
|
||||
0, NULL);
|
||||
TALER_EXCHANGE_track_transfer_cancel (wdh);
|
||||
TALER_EXCHANGE_transfers_get_cancel (wdh);
|
||||
}
|
||||
|
||||
|
||||
@ -325,14 +325,14 @@ handle_track_transfer_finished (void *cls,
|
||||
* @param cb_cls closure for @a cb
|
||||
* @return handle to cancel operation
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransferHandle *
|
||||
TALER_EXCHANGE_track_transfer (struct TALER_EXCHANGE_Handle *exchange,
|
||||
struct TALER_EXCHANGE_TransfersGetHandle *
|
||||
TALER_EXCHANGE_transfers_get (struct TALER_EXCHANGE_Handle *exchange,
|
||||
const struct
|
||||
TALER_WireTransferIdentifierRawP *wtid,
|
||||
TALER_EXCHANGE_TrackTransferCallback cb,
|
||||
TALER_EXCHANGE_TransfersGetCallback cb,
|
||||
void *cb_cls)
|
||||
{
|
||||
struct TALER_EXCHANGE_TrackTransferHandle *wdh;
|
||||
struct TALER_EXCHANGE_TransfersGetHandle *wdh;
|
||||
struct GNUNET_CURL_Context *ctx;
|
||||
CURL *eh;
|
||||
char arg_str[sizeof (struct TALER_WireTransferIdentifierRawP) * 2 + 32];
|
||||
@ -344,7 +344,7 @@ TALER_EXCHANGE_track_transfer (struct TALER_EXCHANGE_Handle *exchange,
|
||||
return NULL;
|
||||
}
|
||||
|
||||
wdh = GNUNET_new (struct TALER_EXCHANGE_TrackTransferHandle);
|
||||
wdh = GNUNET_new (struct TALER_EXCHANGE_TransfersGetHandle);
|
||||
wdh->exchange = exchange;
|
||||
wdh->cb = cb;
|
||||
wdh->cb_cls = cb_cls;
|
||||
@ -384,8 +384,8 @@ TALER_EXCHANGE_track_transfer (struct TALER_EXCHANGE_Handle *exchange,
|
||||
* @param wdh the wire deposits request handle
|
||||
*/
|
||||
void
|
||||
TALER_EXCHANGE_track_transfer_cancel (struct
|
||||
TALER_EXCHANGE_TrackTransferHandle *wdh)
|
||||
TALER_EXCHANGE_transfers_get_cancel (struct
|
||||
TALER_EXCHANGE_TransfersGetHandle *wdh)
|
||||
{
|
||||
if (NULL != wdh->job)
|
||||
{
|
||||
|
@ -55,7 +55,7 @@ struct TALER_EXCHANGE_WireHandle
|
||||
/**
|
||||
* Function to call with the result.
|
||||
*/
|
||||
TALER_EXCHANGE_WireResultCallback cb;
|
||||
TALER_EXCHANGE_WireCallback cb;
|
||||
|
||||
/**
|
||||
* Closure for @a cb.
|
||||
@ -388,7 +388,7 @@ handle_wire_finished (void *cls,
|
||||
*/
|
||||
struct TALER_EXCHANGE_WireHandle *
|
||||
TALER_EXCHANGE_wire (struct TALER_EXCHANGE_Handle *exchange,
|
||||
TALER_EXCHANGE_WireResultCallback wire_cb,
|
||||
TALER_EXCHANGE_WireCallback wire_cb,
|
||||
void *wire_cb_cls)
|
||||
{
|
||||
struct TALER_EXCHANGE_WireHandle *wh;
|
||||
|
@ -227,7 +227,7 @@ deposit_confirmation_run (void *cls,
|
||||
&exchange_sig));
|
||||
keys = TALER_EXCHANGE_get_keys (dcs->is->exchange);
|
||||
GNUNET_assert (NULL != keys);
|
||||
spk = TALER_EXCHANGE_get_exchange_signing_key_info (keys,
|
||||
spk = TALER_EXCHANGE_get_signing_key_info (keys,
|
||||
exchange_pub);
|
||||
|
||||
GNUNET_assert (GNUNET_OK ==
|
||||
|
@ -41,7 +41,7 @@ struct StatusState
|
||||
/**
|
||||
* Handle to the "reserve status" operation.
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveStatusHandle *rsh;
|
||||
struct TALER_EXCHANGE_ReservesGetHandle *rsh;
|
||||
|
||||
/**
|
||||
* Expected reserve balance.
|
||||
@ -169,7 +169,7 @@ status_run (void *cls,
|
||||
TALER_TESTING_interpreter_fail (is);
|
||||
return;
|
||||
}
|
||||
ss->rsh = TALER_EXCHANGE_reserve_status (is->exchange,
|
||||
ss->rsh = TALER_EXCHANGE_reserves_get (is->exchange,
|
||||
reserve_pubp,
|
||||
&reserve_status_cb,
|
||||
ss);
|
||||
@ -195,7 +195,7 @@ status_cleanup (void *cls,
|
||||
"Command %u (%s) did not complete\n",
|
||||
ss->is->ip,
|
||||
cmd->label);
|
||||
TALER_EXCHANGE_reserve_status_cancel (ss->rsh);
|
||||
TALER_EXCHANGE_reserves_get_cancel (ss->rsh);
|
||||
ss->rsh = NULL;
|
||||
}
|
||||
GNUNET_free (ss);
|
||||
|
@ -64,7 +64,7 @@ struct TrackTransactionState
|
||||
/**
|
||||
* Handle to the "track transaction" pending operation.
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransactionHandle *tth;
|
||||
struct TALER_EXCHANGE_DepositGetHandle *tth;
|
||||
|
||||
/**
|
||||
* Interpreter state.
|
||||
@ -124,7 +124,7 @@ struct TrackTransferState
|
||||
/**
|
||||
* Handle to a pending "track transfer" operation.
|
||||
*/
|
||||
struct TALER_EXCHANGE_TrackTransferHandle *tth;
|
||||
struct TALER_EXCHANGE_TransfersGetHandle *tth;
|
||||
|
||||
/**
|
||||
* Interpreter state.
|
||||
@ -327,7 +327,7 @@ track_transaction_run (void *cls,
|
||||
return;
|
||||
}
|
||||
|
||||
tts->tth = TALER_EXCHANGE_track_transaction (is->exchange,
|
||||
tts->tth = TALER_EXCHANGE_deposits_get (is->exchange,
|
||||
merchant_priv,
|
||||
&h_wire_details,
|
||||
&h_contract_terms,
|
||||
@ -357,7 +357,7 @@ track_transaction_cleanup (void *cls,
|
||||
"Command %u (%s) did not complete\n",
|
||||
tts->is->ip,
|
||||
cmd->label);
|
||||
TALER_EXCHANGE_track_transaction_cancel (tts->tth);
|
||||
TALER_EXCHANGE_deposits_get_cancel (tts->tth);
|
||||
tts->tth = NULL;
|
||||
}
|
||||
GNUNET_free (tts);
|
||||
@ -453,7 +453,7 @@ track_transfer_cleanup (void *cls,
|
||||
"Command %u (%s) did not complete\n",
|
||||
tts->is->ip,
|
||||
cmd->label);
|
||||
TALER_EXCHANGE_track_transfer_cancel (tts->tth);
|
||||
TALER_EXCHANGE_transfers_get_cancel (tts->tth);
|
||||
tts->tth = NULL;
|
||||
}
|
||||
GNUNET_free (tts);
|
||||
@ -709,7 +709,7 @@ track_transfer_run (void *cls,
|
||||
}
|
||||
GNUNET_assert (NULL != wtid_ptr);
|
||||
}
|
||||
tts->tth = TALER_EXCHANGE_track_transfer (is->exchange,
|
||||
tts->tth = TALER_EXCHANGE_transfers_get (is->exchange,
|
||||
wtid_ptr,
|
||||
&track_transfer_cb,
|
||||
tts);
|
||||
|
@ -80,7 +80,7 @@ struct WithdrawState
|
||||
/**
|
||||
* Withdraw handle (while operation is running).
|
||||
*/
|
||||
struct TALER_EXCHANGE_ReserveWithdrawHandle *wsh;
|
||||
struct TALER_EXCHANGE_WithdrawHandle *wsh;
|
||||
|
||||
/**
|
||||
* Task scheduled to try later.
|
||||
@ -280,7 +280,7 @@ withdraw_run (void *cls,
|
||||
* would free the old one. */
|
||||
ws->pk = TALER_EXCHANGE_copy_denomination_key (dpk);
|
||||
}
|
||||
ws->wsh = TALER_EXCHANGE_reserve_withdraw (is->exchange,
|
||||
ws->wsh = TALER_EXCHANGE_withdraw (is->exchange,
|
||||
ws->pk,
|
||||
rp,
|
||||
&ws->ps,
|
||||
@ -313,7 +313,7 @@ withdraw_cleanup (void *cls,
|
||||
GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
|
||||
"Command %s did not complete\n",
|
||||
cmd->label);
|
||||
TALER_EXCHANGE_reserve_withdraw_cancel (ws->wsh);
|
||||
TALER_EXCHANGE_withdraw_cancel (ws->wsh);
|
||||
ws->wsh = NULL;
|
||||
}
|
||||
if (NULL != ws->retry_task)
|
||||
|
Loading…
Reference in New Issue
Block a user