summaryrefslogtreecommitdiff
path: root/src/backend
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend')
-rw-r--r--src/backend/anastasis-httpd.c27
-rw-r--r--src/backend/anastasis-httpd_mhd.c18
-rw-r--r--src/backend/anastasis-httpd_mhd.h4
-rw-r--r--src/backend/anastasis-httpd_policy.c2
-rw-r--r--src/backend/anastasis-httpd_policy.h2
-rw-r--r--src/backend/anastasis-httpd_policy_upload.c4
-rw-r--r--src/backend/anastasis-httpd_truth.c11
-rw-r--r--src/backend/anastasis-httpd_truth.h6
-rw-r--r--src/backend/anastasis-httpd_truth_upload.c2
9 files changed, 24 insertions, 52 deletions
diff --git a/src/backend/anastasis-httpd.c b/src/backend/anastasis-httpd.c
index ee7aea7..7c4b068 100644
--- a/src/backend/anastasis-httpd.c
+++ b/src/backend/anastasis-httpd.c
@@ -127,12 +127,12 @@ static struct MHD_Daemon *mhd;
struct ANASTASIS_DatabasePlugin *db;
/**
- * Reschedule context for #SH_ctx.
+ * Reschedule context for #AH_ctx.
*/
static struct GNUNET_CURL_RescheduleContext *rc;
/**
- * Set if we should immediately #MHD_run again.
+ * Set if we should immediately MHD_run() again.
*/
static int triggered;
@@ -232,24 +232,25 @@ AH_trigger_curl (void)
/**
* A client has requested the given url using the given method
- * (#MHD_HTTP_METHOD_GET, #MHD_HTTP_METHOD_PUT,
- * #MHD_HTTP_METHOD_DELETE, #MHD_HTTP_METHOD_POST, etc). The callback
+ * (MHD_HTTP_METHOD_GET, MHD_HTTP_METHOD_PUT,
+ * MHD_HTTP_METHOD_DELETE, MHD_HTTP_METHOD_POST, etc). The callback
* must call MHD callbacks to provide content to give back to the
- * client and return an HTTP status code (i.e. #MHD_HTTP_OK,
- * #MHD_HTTP_NOT_FOUND, etc.).
+ * client and return an HTTP status code (i.e. MHD_HTTP_OK,
+ * MHD_HTTP_NOT_FOUND, etc.).
*
* @param cls argument given together with the function
* pointer when the handler was registered with MHD
+ * @param connection MHD connection handle with further request details
* @param url the requested url
- * @param method the HTTP method used (#MHD_HTTP_METHOD_GET,
- * #MHD_HTTP_METHOD_PUT, etc.)
+ * @param method the HTTP method used (MHD_HTTP_METHOD_GET,
+ * MHD_HTTP_METHOD_PUT, etc.)
* @param version the HTTP version string (i.e.
- * #MHD_HTTP_VERSION_1_1)
+ * MHD_HTTP_VERSION_1_1)
* @param upload_data the data being uploaded (excluding HEADERS,
* for a POST that fits into memory and that is encoded
* with a supported encoding, the POST data will NOT be
* given in upload_data and is instead available as
- * part of #MHD_get_connection_values; very large POST
+ * part of MHD_get_connection_values(); very large POST
* data *will* be made available incrementally in
* @a upload_data)
* @param upload_data_size set initially to the size of the
@@ -262,8 +263,8 @@ AH_trigger_curl (void)
* with plenty of upload data) this allows the application
* to easily associate some request-specific state.
* If necessary, this state can be cleaned up in the
- * global #MHD_RequestCompletedCallback (which
- * can be set with the #MHD_OPTION_NOTIFY_COMPLETED).
+ * global MHD_RequestCompletedCallback (which
+ * can be set with the MHD_OPTION_NOTIFY_COMPLETED).
* Initially, `*con_cls` will be NULL.
* @return #MHD_YES if the connection was handled successfully,
* #MHD_NO if the socket must be closed due to a serious
@@ -537,7 +538,7 @@ handle_mhd_completion_callback (void *cls,
* Function that queries MHD's select sets and
* starts the task waiting for them.
*
- * @param daemon_handle HTTP server to prepare to run
+ * @return task handle for the daemon
*/
static struct GNUNET_SCHEDULER_Task *
prepare_daemon (void)
diff --git a/src/backend/anastasis-httpd_mhd.c b/src/backend/anastasis-httpd_mhd.c
index c39a54c..6d2d898 100644
--- a/src/backend/anastasis-httpd_mhd.c
+++ b/src/backend/anastasis-httpd_mhd.c
@@ -27,14 +27,6 @@
#include "anastasis-httpd_mhd.h"
-/**
- * Function to call to handle the request by sending
- * back static data from the @a rh.
- *
- * @param rh context of the handler
- * @param connection the MHD connection to handle
- * @return MHD result code
- */
MHD_RESULT
TMH_MHD_handler_static_response (struct AH_RequestHandler *rh,
struct MHD_Connection *connection)
@@ -49,21 +41,13 @@ TMH_MHD_handler_static_response (struct AH_RequestHandler *rh,
}
-/**
- * Function to call to handle the request by sending
- * back a redirect to the AGPL source code.
- *
- * @param rh context of the handler
- * @param connection the MHD connection to handle
- * @return MHD result code
- */
MHD_RESULT
TMH_MHD_handler_agpl_redirect (struct AH_RequestHandler *rh,
struct MHD_Connection *connection)
{
(void) rh;
return TALER_MHD_reply_agpl (connection,
- "http://www.git.taler.net/anastasis.git");
+ "https://git.taler.net/anastasis.git");
}
diff --git a/src/backend/anastasis-httpd_mhd.h b/src/backend/anastasis-httpd_mhd.h
index 628abfa..2aa9b28 100644
--- a/src/backend/anastasis-httpd_mhd.h
+++ b/src/backend/anastasis-httpd_mhd.h
@@ -34,10 +34,6 @@
*
* @param rh context of the handler
* @param connection the MHD connection to handle
- * @param[in,out] connection_cls the connection's closure (can be updated)
- * @param upload_data upload data
- * @param[in,out] upload_data_size number of bytes (left) in @a upload_data
- * @param mi merchant backend instance, NULL is allowed in this case!
* @return MHD result code
*/
MHD_RESULT
diff --git a/src/backend/anastasis-httpd_policy.c b/src/backend/anastasis-httpd_policy.c
index 2417e15..0b6597a 100644
--- a/src/backend/anastasis-httpd_policy.c
+++ b/src/backend/anastasis-httpd_policy.c
@@ -43,7 +43,7 @@
* using @a default_http_status on success.
*
* @param connection MHD connection to use
- * @param account account to query
+ * @param account_pub account to query
* @return MHD result code
*/
static MHD_RESULT
diff --git a/src/backend/anastasis-httpd_policy.h b/src/backend/anastasis-httpd_policy.h
index 9fb630d..e40ade9 100644
--- a/src/backend/anastasis-httpd_policy.h
+++ b/src/backend/anastasis-httpd_policy.h
@@ -48,7 +48,7 @@ AH_policy_get (struct MHD_Connection *connection,
* Handle POST /policy/$ACCOUNT_PUB request.
*
* @param connection the MHD connection to handle
- * @param con_cls the connection's closure
+ * @param hc request context
* @param account_pub public key of the account
* @param upload_data upload data
* @param upload_data_size number of bytes (left) in @a upload_data
diff --git a/src/backend/anastasis-httpd_policy_upload.c b/src/backend/anastasis-httpd_policy_upload.c
index bff6028..68eb509 100644
--- a/src/backend/anastasis-httpd_policy_upload.c
+++ b/src/backend/anastasis-httpd_policy_upload.c
@@ -227,8 +227,7 @@ cleanup_ctx (struct TM_HandlerContext *hc)
/**
* Transmit a payment request for @a order_id on @a connection
*
- * @param connection MHD connection
- * @param order_id our backend's order ID
+ * @param[in,out] puc details about the operation
* @return #GNUNET_OK on success
*/
static int
@@ -507,7 +506,6 @@ check_payment_cb (void *cls,
* a payment for the user's account.
*
* @param puc context to begin payment for.
- * @param timeout when to give up trying
*/
static void
await_payment (struct PolicyUploadContext *puc)
diff --git a/src/backend/anastasis-httpd_truth.c b/src/backend/anastasis-httpd_truth.c
index b0b6530..f8962b4 100644
--- a/src/backend/anastasis-httpd_truth.c
+++ b/src/backend/anastasis-httpd_truth.c
@@ -277,9 +277,8 @@ AH_truth_shutdown (void)
/**
* Callback to process a POST /orders/ID/refund request
*
- * @param cls closure
- * @param http_status HTTP status code for this request
- * @param ec taler-specific error code
+ * @param cls closure with a `struct RefundEntry *`
+ * @param hr HTTP response details
* @param taler_refund_uri the refund uri offered to the wallet
* @param h_contract hash of the contract a Browser may need to authorize
* obtaining the HTTP response.
@@ -876,12 +875,6 @@ run_authorization_process (struct MHD_Connection *connection,
}
-/**
- * @param connection the MHD connection to handle
- * @param url handles a URL of the format "/truth/$UUID[&response=$RESPONSE]"
- * @param hc
- * @return MHD result code
- */
MHD_RESULT
AH_handler_truth_get (
struct MHD_Connection *connection,
diff --git a/src/backend/anastasis-httpd_truth.h b/src/backend/anastasis-httpd_truth.h
index 7a1b95f..c0ee474 100644
--- a/src/backend/anastasis-httpd_truth.h
+++ b/src/backend/anastasis-httpd_truth.h
@@ -44,7 +44,7 @@ AH_truth_upload_shutdown (void);
*
* @param connection the MHD connection to handle
* @param truth_uuid the truth UUID
- * @param con_cls
+ * @param hc connection context
* @return MHD result code
*/
MHD_RESULT
@@ -58,13 +58,13 @@ AH_handler_truth_get (
* Handle a POST to /truth/$UUID.
*
* @param connection the MHD connection to handle
- * @param con_cls the connection's closure
+ * @param hc connection context
* @param truth_uuid the truth UUID
* @param truth_data truth data
* @param truth_data_size number of bytes (left) in @a truth_data
* @return MHD result code
*/
-int
+MHD_RESULT
AH_handler_truth_post (
struct MHD_Connection *connection,
struct TM_HandlerContext *hc,
diff --git a/src/backend/anastasis-httpd_truth_upload.c b/src/backend/anastasis-httpd_truth_upload.c
index 130876f..30bd8e6 100644
--- a/src/backend/anastasis-httpd_truth_upload.c
+++ b/src/backend/anastasis-httpd_truth_upload.c
@@ -508,7 +508,7 @@ begin_payment (struct TruthUploadContext *tuc)
}
-int
+MHD_RESULT
AH_handler_truth_post (
struct MHD_Connection *connection,
struct TM_HandlerContext *hc,