godot/modules/mbedtls
Fabio Alessandrelli 60687ce778 Fix certificate generation with mbedtls 2.16.8 .
When generating certificates with
`Crypto.generate_self_signed_certificate` we generate the PEM in a
buffer via `mbedtls_x509write_crt_pem`.

Since version 2.16.8, mbedtls adds spurious data at the end of the
buffer due to internal optimizations, this breaks our logic when we try
to immediately parse it and return a proper `X509Certificate` object.

This commit updates the code to find the actual PEM length to parse
using `strlen`, takes extra caution always adding the terminator to the
buffer, and slightly improve error messages.
2020-09-15 18:47:51 +02:00
..
SCsub
config.py
crypto_mbedtls.cpp Fix certificate generation with mbedtls 2.16.8 . 2020-09-15 18:47:51 +02:00
crypto_mbedtls.h Implement RSA encryption/decryption. 2020-06-18 15:29:39 +02:00
dtls_server_mbedtls.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
dtls_server_mbedtls.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
packet_peer_mbed_dtls.cpp Style: Enforce braces around if blocks and loops 2020-05-14 21:57:34 +02:00
packet_peer_mbed_dtls.h
register_types.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
register_types.h
ssl_context_mbedtls.cpp Style: Enforce braces around if blocks and loops 2020-05-14 21:57:34 +02:00
ssl_context_mbedtls.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
stream_peer_mbedtls.cpp Style: Enforce braces around if blocks and loops 2020-05-14 21:57:34 +02:00
stream_peer_mbedtls.h