From 0453ef45df3970247975f7adef957a8c787a0fc9 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Sat, 17 Apr 2021 20:06:34 +0200 Subject: add ability to change Authorization header in via interpreter command (#6778) --- src/include/taler_testing_lib.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'src/include/taler_testing_lib.h') diff --git a/src/include/taler_testing_lib.h b/src/include/taler_testing_lib.h index 497675344..c0a76c44c 100644 --- a/src/include/taler_testing_lib.h +++ b/src/include/taler_testing_lib.h @@ -575,6 +575,7 @@ TALER_TESTING_interpreter_lookup_command (struct TALER_TESTING_Interpreter *is, struct GNUNET_CURL_Context * TALER_TESTING_interpreter_get_context (struct TALER_TESTING_Interpreter *is); + /** * Obtain label of the command being now run. * @@ -931,6 +932,21 @@ TALER_TESTING_has_in_name (const char *prog, /* ************** Specific interpreter commands ************ */ +/** + * Command to modify authorization header used in the CURL context. + * This will destroy the existing CURL context and create a fresh + * one. The command will fail (badly) if the existing CURL context + * still has active HTTP requests associated with it. + * + * @param label command label. + * @param auth_token auth token to use henceforth, can be NULL + * @return the command. + */ +struct TALER_TESTING_Command +TALER_TESTING_cmd_set_authorization (const char *label, + const char *auth_token); + + /** * Make a credit "history" CMD. * -- cgit v1.2.3