aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2024-03-10 12:39:37 +0100
committerChristian Grothoff <christian@grothoff.org>2024-03-10 12:39:37 +0100
commit6606cd92c98f654774624e1812e0915c39cde4ee (patch)
treecf4b8cb1d622ddd075a624d90659fab9013fe5f6 /src
parentdc26c14f4cf0beb83d8eef28baf84b56c8d3ef86 (diff)
sanity-check conversion URL
Diffstat (limited to 'src')
-rw-r--r--src/exchange-tools/taler-exchange-offline.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/exchange-tools/taler-exchange-offline.c b/src/exchange-tools/taler-exchange-offline.c
index 2ad2342fe..50ec0ff96 100644
--- a/src/exchange-tools/taler-exchange-offline.c
+++ b/src/exchange-tools/taler-exchange-offline.c
@@ -3167,6 +3167,17 @@ do_add_wire (char *const *args)
json_decref (credit_restrictions);
return;
}
+ if (! TALER_is_web_url (conversion_url))
+ {
+ GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
+ "'conversion-url' must refer to HTTP(S) endpoint, `%s' is invalid\n",
+ conversion_url);
+ global_ret = EXIT_INVALIDARGUMENT;
+ test_shutdown ();
+ json_decref (debit_restrictions);
+ json_decref (credit_restrictions);
+ return;
+ }
num_args++;
continue;
}