Reading Certificates from Spiffs partition on the flash memory of esp32
Posted: Wed May 27, 2020 6:45 am
I am able to flash the certificates on siffs partition and access the certificates using file handling but how do i load then for SSL server certification and esp_http_client_config_t.
I was previously embedding the certificates into the firmware using the components.mk file like this
and then using them like this
But I don't know how to load them from the spiffs partition in the flash memory. Can somebody please help me out ?
Thanks
Saransh Goel
I was previously embedding the certificates into the firmware using the components.mk file like this
Code: Select all
COMPONENT_EMBED_TXTFILES = device_cert.pem
Code: Select all
extern const uint8_t device_cert_pem_start[] asm("_binary_device_cert_pem_start");
extern const uint8_t device_cert_pem_end[] asm("_binary_device_cert__pem_end");
Thanks
Saransh Goel