mirror of
https://github.com/espressif/ESP8266_RTOS_SDK.git
synced 2025-07-01 22:28:37 +08:00
update make_cert.py
This commit is contained in:
@ -23,7 +23,7 @@ Clone ESP8266_RTOS_SDK, e.g., to ~/ESP8266_RTOS_SDK.
|
||||
$git clone https://github.com/espressif/ESP8266_RTOS_SDK.git
|
||||
|
||||
Modify gen_misc.sh or gen_misc.bat:
|
||||
For Linux<EFBFBD><EFBFBD>
|
||||
For Linux:
|
||||
|
||||
$export SDK_PATH=~/ESP8266_RTOS_SDK
|
||||
$export BIN_PATH=~/ESP8266_BIN
|
||||
|
@ -25,12 +25,11 @@ def main():
|
||||
file_list = os.listdir(os.getcwd())
|
||||
cert_file_list = []
|
||||
for _file in file_list:
|
||||
pos = _file.find(".cer")
|
||||
if pos != -1:
|
||||
cert_file_list.append(_file[:pos])
|
||||
|
||||
if _file.endswith(".cer") or _file.endswith(".key"):
|
||||
cert_file_list.append(_file)
|
||||
print cert_file_list
|
||||
for cert_file in cert_file_list:
|
||||
with open(cert_file+".cer", 'rb') as f:
|
||||
with open(cert_file, 'rb') as f:
|
||||
buff = f.read()
|
||||
cert_list.append(Cert(cert_file, buff))
|
||||
with open('esp_ca_cert.bin', 'wb+') as f:
|
||||
|
Reference in New Issue
Block a user