mbedtls
mbedtls copied to clipboard
mbedtls is unable to load PEM files with comments
Summary
mbedtls_x509_crt_parse/mbedtls_x509_crt_parse_file are unable to correctly parse PEM files with comments and mistakenly treat such files as DER, resulting in failed parsing. Example file that contains all Mozilla's certificates
System information
Mbed TLS version (number or commit id): 3.5.2 Operating system and version: any system
Expected behavior
Skip comments and load such a PEM file
Actual behavior
Failed parsing