API for subscribing certificate renewal notications and renewing certificates. More...
#include "pt-client-2/pt_common_api.h"
Go to the source code of this file.
Macros | |
#define | PT_API_VERSION 2 |
#define | PT_CERTIFICATE_API_H_ |
Typedefs | |
typedef struct pt_certificate_list | pt_certificate_list_t |
typedef void(* | pt_certificates_set_response_handler) (const connection_id_t connection_id, void *userdata) |
Type definition for pt_certificate_renewal_list_set response success and failure handlers. More... | |
typedef void(* | pt_certificate_renew_response_handler) (const connection_id_t connection_id, void *userdata) |
Type definition for pt_certificate_renew response success and failure handlers. | |
Functions | |
pt_certificate_list_t * | pt_certificate_list_create () |
Creates a certificate list. More... | |
void | pt_certificate_list_destroy (pt_certificate_list_t *list) |
Destroys the certificate list. Frees all the certificates added to the list. | |
pt_status_t | pt_certificate_list_add (pt_certificate_list_t *list, const char *name) |
Adds a certificate to certificate list. More... | |
pt_status_t | pt_certificate_renewal_list_set (const connection_id_t connection_id, pt_certificate_list_t *list, pt_certificates_set_response_handler success_handler, pt_certificates_set_response_handler failure_handler, void *userdata) |
Sends the certificate list to Edge, triggering renewal subscriptions of the certificates in the list. More... | |
pt_status_t | pt_certificate_renew (const connection_id_t connection_id, const char *name, pt_certificate_renew_response_handler success_handler, pt_certificate_renew_response_handler failure_handler, void *userdata) |
Requests the renewal of the certificate specified by the name parameter. More... | |
API for subscribing certificate renewal notications and renewing certificates.
To be able to renew a certificate:
pt_client_create
.pt_certificate_list_add
) to certificate list that was created using pt_certificate_list_create
.pt_certificate_renewal_list_set
.pt_certificate_renew
must be called for the certificates that were added to the list.After setting notification callback and subscribing to certificate renewals, the client must also be prepared to receive certificate renewal notification callback also for cloud initiated certificate renewal.