This is a fork of the mbed port of axTLS
Dependents: TLS_axTLS-Example HTTPSClientExample
CertificateManager Class Reference
This class is in charge of loading and storing certificates. More...
#include <CertificateManager.h>
Static Public Member Functions | |
static void | add (const char *fileName) |
Add a certificate to load. | |
static bool | load (const bool precompute=false) |
Load certificates. | |
static void | clear () |
Clear everything. |
Detailed Description
This class is in charge of loading and storing certificates.
Example:
#include "mbed.h" #include "CertificateManager.h LocalFileSystem local("/local/"); int main(void) { CertificateManager::add("/local/root.der"); if(!CertificateManager::load()) printf("Error while loading certificates\n"); return 0; }
Definition at line 30 of file CertificateManager.h.
Member Function Documentation
void add | ( | const char * | fileName ) | [static] |
Add a certificate to load.
- Parameters:
-
fileName Certificate's filename.
- Note:
- This function does not load the certificate and does not check if the file exists.
Definition at line 24 of file CertificateManager.cpp.
void clear | ( | ) | [static] |
Clear everything.
- Note:
- This function should be called once a TLS connection is established with success.
Definition at line 221 of file CertificateManager.cpp.
bool load | ( | const bool | precompute = false ) |
[static] |
Load certificates.
- Parameters:
-
precompute Tells the certificate manager how to load certificates.
- Returns:
- True if certificates were loaded with success, false otherwise.
- Note:
- If the loading fails, everything is cleared. So, you have to add again all certificates you need.
Definition at line 29 of file CertificateManager.cpp.
Generated on Wed Jul 13 2022 19:30:08 by 1.7.2