aboutsummaryrefslogtreecommitdiff
path: root/src/mint/taler-mint-httpd_responses.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2015-01-28 14:55:25 +0100
committerChristian Grothoff <christian@grothoff.org>2015-01-28 14:55:25 +0100
commit49d4f24f8d031a9301676196bd6a17ea3e54cb62 (patch)
tree3bb4e1a73fff39eaf68839bba723be63f3ace6ad /src/mint/taler-mint-httpd_responses.c
parentea3fac606311d1c14362d387960a4913182b629e (diff)
misc cleanup, moving TALER_MINT_config_load to libtalerutil
Diffstat (limited to 'src/mint/taler-mint-httpd_responses.c')
-rw-r--r--src/mint/taler-mint-httpd_responses.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/mint/taler-mint-httpd_responses.c b/src/mint/taler-mint-httpd_responses.c
index 12d4bced7..432772d79 100644
--- a/src/mint/taler-mint-httpd_responses.c
+++ b/src/mint/taler-mint-httpd_responses.c
@@ -125,6 +125,26 @@ TALER_MINT_reply_arg_invalid (struct MHD_Connection *connection,
/**
+ * Send a response indicating an invalid coin. (I.e. the signature
+ * over the public key of the coin does not match a valid signing key
+ * of this mint).
+ *
+ * @param connection the MHD connection to use
+ * @return MHD result code
+ */
+int
+TALER_MINT_reply_coin_invalid (struct MHD_Connection *connection)
+{
+ /* TODO: may want to be more precise in the future and
+ distinguish bogus signatures from bogus public keys. */
+ return TALER_MINT_reply_json_pack (connection,
+ MHD_HTTP_NOT_FOUND,
+ "{s:s}",
+ "error", "Coin is not valid");
+}
+
+
+/**
* Send a response indicating a missing argument.
*
* @param connection the MHD connection to use