Dealocate memory for subject alt names

Signed-off-by: Przemek Stekiel <przemyslaw.stekiel@mobica.com>
This commit is contained in:
Przemek Stekiel 2023-01-24 15:19:47 +01:00
parent 86d1946164
commit a468768000

View file

@ -581,6 +581,7 @@ void mbedtls_x509_csr_free(mbedtls_x509_csr *csr)
#endif
mbedtls_asn1_free_named_data_list_shallow(csr->subject.next);
mbedtls_asn1_sequence_free(csr->subject_alt_names.next);
if (csr->raw.p != NULL) {
mbedtls_platform_zeroize(csr->raw.p, csr->raw.len);