ESP32 服务器证书如何用数组保存起来。
2019-08-01 本文已影响0人
昨天剩下的一杯冷茶
问题原因:
ESP32的证书server_root_cert.pem都是自动的嵌入式到固件里去的。
最后通过下面2个数组来获取证书数据和长度。
extern const uint8_t server_root_cert_pem_start[] asm("_binary_server_root_cert_pem_start");
extern const uint8_t server_root_cert_pem_end[] asm("_binary_server_root_cert_pem_end");
但是程序中证书是不固定的,那有没有办法将证书用一个数组保存起来呢?
答案是有的。
说明文档下载地址:
https://download.csdn.net/download/qq_31806069/11459881