|
Apache HTTPD
|
#include <assert.h>#include <stdlib.h>#include <apr_lib.h>#include <apr_strings.h>#include <apr_buckets.h>#include <apr_hash.h>#include <apr_uri.h>#include "md.h"#include "md_crypt.h"#include "md_json.h"#include "md_jws.h"#include "md_http.h"#include "md_log.h"#include "md_store.h"#include "md_result.h"#include "md_util.h"#include "md_version.h"#include "md_acme.h"#include "md_acme_acct.h"Go to the source code of this file.
Classes | |
| struct | acme_problem_status_t |
| struct | json_ctx |
| struct | update_dir_ctx |
Typedefs | |
| typedef struct acme_problem_status_t | acme_problem_status_t |
Variables | |
| static const char * | base_product = "-" |
| static acme_problem_status_t | Problems [] |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
| void md_acme_clear_acct | ( | md_acme_t * | acme | ) |
| apr_status_t md_acme_create | ( | md_acme_t ** | pacme, |
| apr_pool_t * | p, | ||
| const char * | url, | ||
| const char * | proxy_url, | ||
| const char * | ca_file | ||
| ) |
Create a new ACME server instance. If path is not NULL, will use that directory for persisting information. Will load any information persisted in earlier session. url needs only be specified for instances where this has never been persisted before.
| pacme | will hold the ACME server instance on success |
| p | pool to used |
| url | url of the server, optional if known at path |
| proxy_url | optional url of a HTTP(S) proxy to use |
| apr_status_t md_acme_GET | ( | md_acme_t * | acme, |
| const char * | url, | ||
| md_acme_req_init_cb * | on_init, | ||
| md_acme_req_json_cb * | on_json, | ||
| md_acme_req_res_cb * | on_res, | ||
| md_acme_req_err_cb * | on_err, | ||
| void * | baton | ||
| ) |
| apr_status_t md_acme_get_json | ( | struct md_json_t ** | pjson, |
| md_acme_t * | acme, | ||
| const char * | url, | ||
| apr_pool_t * | p | ||
| ) |
| apr_status_t md_acme_init | ( | apr_pool_t * | pool, |
| const char * | base_version, | ||
| int | init_ssl | ||
| ) |
| apr_status_t md_acme_POST | ( | md_acme_t * | acme, |
| const char * | url, | ||
| md_acme_req_init_cb * | on_init, | ||
| md_acme_req_json_cb * | on_json, | ||
| md_acme_req_res_cb * | on_res, | ||
| md_acme_req_err_cb * | on_err, | ||
| void * | baton | ||
| ) |
Perform a POST against the ACME url. If a on_json callback is given and the HTTP response is JSON, only this callback is invoked. Otherwise, on HTTP status 2xx, the on_res callback is invoked. If no on_res is given, it is considered a response error, since only JSON was expected. At least one callback needs to be non-NULL.
| acme | the ACME server to talk to |
| url | the url to send the request to |
| on_init | callback to initialize the request data |
| on_json | callback on successful JSON response |
| on_res | callback on successful HTTP response |
| baton | userdata for callbacks |
| apr_status_t md_acme_POST_new_account | ( | md_acme_t * | acme, |
| md_acme_req_init_cb * | on_init, | ||
| md_acme_req_json_cb * | on_json, | ||
| md_acme_req_res_cb * | on_res, | ||
| md_acme_req_err_cb * | on_err, | ||
| void * | baton | ||
| ) |
| void md_acme_report_result | ( | md_acme_t * | acme, |
| apr_status_t | rv, | ||
| struct md_result_t * | result | ||
| ) |
| apr_status_t md_acme_req_body_init | ( | md_acme_req_t * | req, |
| md_json_t * | payload | ||
| ) |
|
static |
|
static |
| apr_status_t md_acme_save_acct | ( | md_acme_t * | acme, |
| apr_pool_t * | p, | ||
| md_store_t * | store | ||
| ) |
| apr_status_t md_acme_setup | ( | md_acme_t * | acme, |
| struct md_result_t * | result | ||
| ) |
| apr_status_t md_acme_use_acct | ( | md_acme_t * | acme, |
| struct md_store_t * | store, | ||
| apr_pool_t * | p, | ||
| const char * | acct_id | ||
| ) |
Specify the account to use by name in local store. On success, the account is the "current" one used by the acme instance.
| acme | the acme instance to set the account for |
| store | the store to load accounts from |
| p | pool for allocations |
| acct_id | name of the account to load |
| apr_status_t md_acme_use_acct_for_md | ( | md_acme_t * | acme, |
| struct md_store_t * | store, | ||
| apr_pool_t * | p, | ||
| const char * | acct_id, | ||
| const md_t * | md | ||
| ) |
Specify the account to use for a specific MD by name in local store. On success, the account is the "current" one used by the acme instance.
| acme | the acme instance to set the account for |
| store | the store to load accounts from |
| p | pool for allocations |
| acct_id | name of the account to load |
| md | the MD the account shall be used for |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |