diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e7cb136..cd457f9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -70,7 +70,7 @@ jobs: minos: 7.0 runs-on: macos-12 env: - MBEDTLS_VERSION: 3.3.0 + MBEDTLS_VERSION: 3.4.0 READLINE_VERSION: 8.2 SLANG_VERSION: 2.3.3 NEWT_VERSION: 0.52.23 @@ -494,7 +494,7 @@ jobs: - aarch64-linux-musl runs-on: ubuntu-latest env: - MBEDTLS_VERSION: 3.3.0 + MBEDTLS_VERSION: 3.4.0 LIBUSB_VERSION: 1.0.26 READLINE_VERSION: 8.2 SLANG_VERSION: 2.3.3 diff --git a/patches/mbedtls/0001-Allow-empty-x509-cert-issuer.patch b/patches/mbedtls/0001-Allow-empty-x509-cert-issuer.patch index 6696609..2489d93 100644 --- a/patches/mbedtls/0001-Allow-empty-x509-cert-issuer.patch +++ b/patches/mbedtls/0001-Allow-empty-x509-cert-issuer.patch @@ -1,35 +1,34 @@ -From 632cdb6de3f1693fb90d60d81552b723e8dd5e84 Mon Sep 17 00:00:00 2001 +From 2c8190847d4bd07db579bdea954d44fcf506a926 Mon Sep 17 00:00:00 2001 From: Nick Chan -Date: Wed, 25 Jan 2023 01:53:00 +0800 +Date: Sat, 27 May 2023 20:54:54 +0800 Subject: [PATCH] Allow empty x509 cert issuer --- - library/x509_crt.c | 8 ++++---- - 1 file changed, 4 insertions(+), 4 deletions(-) + library/x509_crt.c | 11 ----------- + 1 file changed, 11 deletions(-) diff --git a/library/x509_crt.c b/library/x509_crt.c -index 0eee97cb6..46702f683 100644 +index cf62532f2..a753b0aec 100644 --- a/library/x509_crt.c +++ b/library/x509_crt.c -@@ -1185,14 +1185,14 @@ static int x509_crt_parse_der_core( mbedtls_x509_crt *crt, - if( ( ret = mbedtls_asn1_get_tag( &p, end, &len, - MBEDTLS_ASN1_CONSTRUCTED | MBEDTLS_ASN1_SEQUENCE ) ) != 0 ) - { -- mbedtls_x509_crt_free( crt ); -- return( MBEDTLS_ERROR_ADD( MBEDTLS_ERR_X509_INVALID_FORMAT, ret ) ); -+ // mbedtls_x509_crt_free( crt ); -+ // return( MBEDTLS_ERROR_ADD( MBEDTLS_ERR_X509_INVALID_FORMAT, ret ) ); - } - - if( ( ret = mbedtls_x509_get_name( &p, p + len, &crt->issuer ) ) != 0 ) - { -- mbedtls_x509_crt_free( crt ); -- return( ret ); -+ // mbedtls_x509_crt_free( crt ); -+ // return( ret ); - } +@@ -1059,17 +1059,6 @@ static int x509_crt_parse_der_core(mbedtls_x509_crt *crt, + */ + crt->issuer_raw.p = p; +- if ((ret = mbedtls_asn1_get_tag(&p, end, &len, +- MBEDTLS_ASN1_CONSTRUCTED | MBEDTLS_ASN1_SEQUENCE)) != 0) { +- mbedtls_x509_crt_free(crt); +- return MBEDTLS_ERROR_ADD(MBEDTLS_ERR_X509_INVALID_FORMAT, ret); +- } +- +- if ((ret = mbedtls_x509_get_name(&p, p + len, &crt->issuer)) != 0) { +- mbedtls_x509_crt_free(crt); +- return ret; +- } +- crt->issuer_raw.len = p - crt->issuer_raw.p; + + /* -- 2.39.1