acme_dns_client.c
#define ACME_DNS_CLIENT_MAX_PASSWORD_LEN
Definition: acme_dns_client.h:83
error_t httpClientDisconnect(HttpClientContext *context)
Gracefully disconnect from the HTTP server.
Definition: http_client.c:2149
error_t httpClientCloseBody(HttpClientContext *context)
Close HTTP request or response body.
Definition: http_client.c:2012
error_t httpClientBindToInterface(HttpClientContext *context, NetInterface *interface)
Bind the HTTP client to a particular network interface.
Definition: http_client.c:246
error_t acmeDnsClientSetHost(AcmeDnsClientContext *context, const char_t *host)
Set the domain name of the ACME-DNS server.
Definition: acme_dns_client.c:131
const char_t * acmeDnsClientGetFullDomain(AcmeDnsClientContext *context)
Get full domain.
Definition: acme_dns_client.c:309
error_t httpClientReadBody(HttpClientContext *context, void *data, size_t size, size_t *received, uint_t flags)
Read HTTP response body.
Definition: http_client.c:1646
error_t acmeDnsClientSetSubDomain(AcmeDnsClientContext *context, const char_t *subDomain)
Set sub domain.
Definition: acme_dns_client.c:209
ACME-DNS client.
error_t acmeDnsClientDisconnect(AcmeDnsClientContext *context)
Gracefully disconnect from the ACME-DNS server.
Definition: acme_dns_client.c:773
const char_t * acmeDnsClientGetSubDomain(AcmeDnsClientContext *context)
Get sub domain.
Definition: acme_dns_client.c:284
@ ACME_DNS_CLIENT_STATE_DISCONNECTED
Definition: acme_dns_client.h:127
Helper functions for ACME-DNS client.
const char_t * acmeDnsClientGetUsername(AcmeDnsClientContext *context)
Get user name.
Definition: acme_dns_client.c:234
error_t httpClientSetVersion(HttpClientContext *context, HttpVersion version)
Set the HTTP protocol version to be used.
Definition: http_client.c:162
error_t acmeDnsClientRegister(AcmeDnsClientContext *context)
Register endpoint.
Definition: acme_dns_client.c:460
error_t acmeDnsClientParseRegisterResponse(AcmeDnsClientContext *context)
Parse HTTP response (register endpoint)
Definition: acme_dns_client_misc.c:111
void httpClientDeinit(HttpClientContext *context)
Release HTTP client context.
Definition: http_client.c:2245
error_t httpClientWriteHeader(HttpClientContext *context)
Write HTTP request header.
Definition: http_client.c:1014
const char_t * acmeDnsClientGetPassword(AcmeDnsClientContext *context)
Get password.
Definition: acme_dns_client.c:259
@ ACME_DNS_CLIENT_STATE_RECEIVE_HEADER
Definition: acme_dns_client.h:132
error_t httpClientRegisterTlsInitCallback(HttpClientContext *context, HttpClientTlsInitCallback callback)
Register TLS initialization callback function.
Definition: http_client.c:111
error_t httpClientSetTimeout(HttpClientContext *context, systime_t timeout)
Set communication timeout.
Definition: http_client.c:187
error_t httpClientClose(HttpClientContext *context)
Close the connection with the HTTP server.
Definition: http_client.c:2224
error_t acmeDnsClientFormatUpdateRequest(AcmeDnsClientContext *context, const char_t *txt)
Format HTTP request body (update endpoint)
Definition: acme_dns_client_misc.c:199
error_t httpClientInit(HttpClientContext *context)
Initialize HTTP client context.
Definition: http_client.c:66
error_t acmeDnsClientParseUpdateResponse(AcmeDnsClientContext *context)
Parse HTTP response (update endpoint)
Definition: acme_dns_client_misc.c:275
uint_t httpClientGetStatus(HttpClientContext *context)
Retrieve the HTTP status code of the response.
Definition: http_client.c:1512
error_t httpClientReadHeader(HttpClientContext *context)
Read HTTP response header.
Definition: http_client.c:1372
@ ACME_DNS_CLIENT_STATE_DISCONNECTING
Definition: acme_dns_client.h:137
error_t acmeDnsClientSetUsername(AcmeDnsClientContext *context, const char_t *username)
Set user name.
Definition: acme_dns_client.c:157
error_t acmeDnsClientFormatRegisterRequest(AcmeDnsClientContext *context)
Format HTTP request body (register endpoint)
Definition: acme_dns_client_misc.c:50
@ ACME_DNS_CLIENT_STATE_PARSE_HEADER
Definition: acme_dns_client.h:133
error_t httpClientConnect(HttpClientContext *context, const IpAddr *serverIpAddr, uint16_t serverPort)
Establish a connection with the specified HTTP server.
Definition: http_client.c:269
#define ACME_DNS_CLIENT_DEFAULT_TIMEOUT
Definition: acme_dns_client.h:55
@ ACME_DNS_CLIENT_STATE_RECEIVE_BODY
Definition: acme_dns_client.h:134
error_t httpClientWriteBody(HttpClientContext *context, const void *data, size_t length, size_t *written, uint_t flags)
Write HTTP request body.
Definition: http_client.c:1137
error_t acmeDnsClientBindToInterface(AcmeDnsClientContext *context, NetInterface *interface)
Bind the ACME-DNS client to a particular network interface.
Definition: acme_dns_client.c:335
error_t(* AcmeDnsClientTlsInitCallback)(HttpClientContext *context, TlsContext *tlsContext)
TLS initialization callback function.
Definition: acme_dns_client.h:148
#define ACME_DNS_CLIENT_MAX_SUB_DOMAIN_LEN
Definition: acme_dns_client.h:90
error_t acmeDnsClientSetPassword(AcmeDnsClientContext *context, const char_t *password)
Set password.
Definition: acme_dns_client.c:183
error_t acmeDnsClientInit(AcmeDnsClientContext *context)
Initialize ACME-DNS client context.
Definition: acme_dns_client.c:49
error_t acmeDnsClientConnect(AcmeDnsClientContext *context, const IpAddr *serverIpAddr, uint16_t serverPort)
Establish a connection with the specified ACME-DNS server.
Definition: acme_dns_client.c:358
error_t acmeDnsClientUpdate(AcmeDnsClientContext *context, const char_t *txt)
Update endpoint.
Definition: acme_dns_client.c:602
@ ACME_DNS_CLIENT_STATE_SEND_HEADER
Definition: acme_dns_client.h:130
error_t acmeDnsClientSetTimeout(AcmeDnsClientContext *context, systime_t timeout)
Set communication timeout.
Definition: acme_dns_client.c:109
error_t acmeDnsClientRegisterTlsInitCallback(AcmeDnsClientContext *context, AcmeDnsClientTlsInitCallback callback)
Register TLS initialization callback function.
Definition: acme_dns_client.c:85
void acmeDnsClientDeinit(AcmeDnsClientContext *context)
Release ACME-DNS client context.
Definition: acme_dns_client.c:860
error_t acmeDnsClientClose(AcmeDnsClientContext *context)
Close the connection with the ACME-DNS server.
Definition: acme_dns_client.c:839
Debugging facilities.
#define ACME_DNS_CLIENT_MAX_USERNAME_LEN
Definition: acme_dns_client.h:76