summaryrefslogtreecommitdiff
path: root/src/wire/plugin_wire_template.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2016-04-02 20:58:22 +0200
committerChristian Grothoff <christian@grothoff.org>2016-04-02 20:58:22 +0200
commitdaae3d3ddf1cbee4761a6a2c0066732fb4723fb0 (patch)
treeba2e9a677f6a1bede7f871adc9ca0c97ac62e7c6 /src/wire/plugin_wire_template.c
parent937078bbdc747c92d45a3879862ff4664d1ff636 (diff)
downloadexchange-daae3d3ddf1cbee4761a6a2c0066732fb4723fb0.tar.gz
exchange-daae3d3ddf1cbee4761a6a2c0066732fb4723fb0.tar.bz2
exchange-daae3d3ddf1cbee4761a6a2c0066732fb4723fb0.zip
change taler-exchange-sepa to a more generic taler-exchange-wire tool using the wire plugins (#4237)
Diffstat (limited to 'src/wire/plugin_wire_template.c')
-rw-r--r--src/wire/plugin_wire_template.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/wire/plugin_wire_template.c b/src/wire/plugin_wire_template.c
index fd6fbfbe9..46908c297 100644
--- a/src/wire/plugin_wire_template.c
+++ b/src/wire/plugin_wire_template.c
@@ -172,6 +172,28 @@ template_execute_wire_transfer (void *cls,
/**
+ * Sign wire transfer details in the plugin-specific format.
+ *
+ * @param cls closure
+ * @param in wire transfer details in JSON format
+ * @param key private signing key to use
+ * @param salt salt to add
+ * @param[out] sig where to write the signature
+ * @return #GNUNET_OK on success
+ */
+static int
+template_sign_wire_details (void *cls,
+ const json_t *in,
+ const struct TALER_MasterPrivateKeyP *key,
+ const struct GNUNET_HashCode *salt,
+ struct TALER_MasterSignatureP *sig)
+{
+ GNUNET_break (0);
+ return GNUNET_SYSERR;
+}
+
+
+/**
* Abort execution of a wire transfer. For example, because we are
* shutting down. Note that if an execution is aborted, it may or
* may not still succeed. The caller MUST run @e
@@ -236,6 +258,7 @@ libtaler_plugin_wire_template_init (void *cls)
plugin->cls = tc;
plugin->amount_round = &template_amount_round;
plugin->get_wire_details = &template_get_wire_details;
+ plugin->sign_wire_details = &template_sign_wire_details;
plugin->wire_validate = &template_wire_validate;
plugin->prepare_wire_transfer = &template_prepare_wire_transfer;
plugin->prepare_wire_transfer_cancel = &template_prepare_wire_transfer_cancel;