diff options
Diffstat (limited to 'src/credential/plugin_rest_credential.c')
-rw-r--r-- | src/credential/plugin_rest_credential.c | 43 |
1 files changed, 5 insertions, 38 deletions
diff --git a/src/credential/plugin_rest_credential.c b/src/credential/plugin_rest_credential.c index 48d48fba0..480658822 100644 --- a/src/credential/plugin_rest_credential.c +++ b/src/credential/plugin_rest_credential.c | |||
@@ -19,7 +19,7 @@ | |||
19 | */ | 19 | */ |
20 | /** | 20 | /** |
21 | * @author Martin Schanzenbach | 21 | * @author Martin Schanzenbach |
22 | * @file gns/plugin_rest_credential.c | 22 | * @file credential/plugin_rest_credential.c |
23 | * @brief GNUnet CREDENTIAL REST plugin | 23 | * @brief GNUnet CREDENTIAL REST plugin |
24 | * | 24 | * |
25 | */ | 25 | */ |
@@ -194,12 +194,6 @@ cleanup_handle (struct RequestHandle *handle) | |||
194 | } | 194 | } |
195 | 195 | ||
196 | 196 | ||
197 | /** | ||
198 | * Task run on shutdown. Cleans up everything. | ||
199 | * | ||
200 | * @param cls unused | ||
201 | * @param tc scheduler context | ||
202 | */ | ||
203 | static void | 197 | static void |
204 | do_error (void *cls) | 198 | do_error (void *cls) |
205 | { | 199 | { |
@@ -213,7 +207,8 @@ do_error (void *cls) | |||
213 | 207 | ||
214 | /** | 208 | /** |
215 | * Attribute delegation to JSON | 209 | * Attribute delegation to JSON |
216 | * @param attr the attribute | 210 | * |
211 | * @param delegation_chain_entry the DSE | ||
217 | * @return JSON, NULL if failed | 212 | * @return JSON, NULL if failed |
218 | */ | 213 | */ |
219 | static json_t* | 214 | static json_t* |
@@ -257,6 +252,7 @@ attribute_delegation_to_json (struct GNUNET_CREDENTIAL_Delegation *delegation_ch | |||
257 | 252 | ||
258 | /** | 253 | /** |
259 | * JSONAPI resource to Credential | 254 | * JSONAPI resource to Credential |
255 | * | ||
260 | * @param res the JSONAPI resource | 256 | * @param res the JSONAPI resource |
261 | * @return the resulting credential, NULL if failed | 257 | * @return the resulting credential, NULL if failed |
262 | */ | 258 | */ |
@@ -327,6 +323,7 @@ json_to_credential (json_t *res) | |||
327 | 323 | ||
328 | /** | 324 | /** |
329 | * Credential to JSON | 325 | * Credential to JSON |
326 | * | ||
330 | * @param cred the credential | 327 | * @param cred the credential |
331 | * @return the resulting json, NULL if failed | 328 | * @return the resulting json, NULL if failed |
332 | */ | 329 | */ |
@@ -373,13 +370,6 @@ credential_to_json (struct GNUNET_CREDENTIAL_Credential *cred) | |||
373 | return cred_obj; | 370 | return cred_obj; |
374 | } | 371 | } |
375 | 372 | ||
376 | /** | ||
377 | * Function called with the result of a Credential lookup. | ||
378 | * | ||
379 | * @param cls the 'const char *' name that was resolved | ||
380 | * @param cd_count number of records returned | ||
381 | * @param cd array of @a cd_count records with the results | ||
382 | */ | ||
383 | static void | 373 | static void |
384 | handle_collect_response (void *cls, | 374 | handle_collect_response (void *cls, |
385 | unsigned int d_count, | 375 | unsigned int d_count, |
@@ -470,13 +460,6 @@ subject_ego_lookup (void *cls, | |||
470 | 460 | ||
471 | 461 | ||
472 | 462 | ||
473 | /** | ||
474 | * Function called with the result of a Credential lookup. | ||
475 | * | ||
476 | * @param cls the 'const char *' name that was resolved | ||
477 | * @param cd_count number of records returned | ||
478 | * @param cd array of @a cd_count records with the results | ||
479 | */ | ||
480 | static void | 463 | static void |
481 | handle_verify_response (void *cls, | 464 | handle_verify_response (void *cls, |
482 | unsigned int d_count, | 465 | unsigned int d_count, |
@@ -1062,11 +1045,6 @@ issue_cred_cont (struct GNUNET_REST_RequestHandle *conndata_handle, | |||
1062 | handle); | 1045 | handle); |
1063 | } | 1046 | } |
1064 | 1047 | ||
1065 | /** | ||
1066 | * Handle rest request | ||
1067 | * | ||
1068 | * @param handle the lookup handle | ||
1069 | */ | ||
1070 | static void | 1048 | static void |
1071 | options_cont (struct GNUNET_REST_RequestHandle *con_handle, | 1049 | options_cont (struct GNUNET_REST_RequestHandle *con_handle, |
1072 | const char* url, | 1050 | const char* url, |
@@ -1087,17 +1065,6 @@ options_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1087 | } | 1065 | } |
1088 | 1066 | ||
1089 | 1067 | ||
1090 | /** | ||
1091 | * Function processing the REST call | ||
1092 | * | ||
1093 | * @param method HTTP method | ||
1094 | * @param url URL of the HTTP request | ||
1095 | * @param data body of the HTTP request (optional) | ||
1096 | * @param data_size length of the body | ||
1097 | * @param proc callback function for the result | ||
1098 | * @param proc_cls closure for callback function | ||
1099 | * @return GNUNET_OK if request accepted | ||
1100 | */ | ||
1101 | static void | 1068 | static void |
1102 | rest_credential_process_request(struct GNUNET_REST_RequestHandle *conndata_handle, | 1069 | rest_credential_process_request(struct GNUNET_REST_RequestHandle *conndata_handle, |
1103 | GNUNET_REST_ResultProcessor proc, | 1070 | GNUNET_REST_ResultProcessor proc, |