CVE-2025-47917

Source
https://cve.org/CVERecord?id=CVE-2025-47917
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2025-47917.json
JSON Data
https://api.test.osv.dev/v1/vulns/CVE-2025-47917
Downstream
Related
Published
2025-07-20T00:00:00Z
Modified
2026-08-19T11:48:44Z
Severity
  • 8.9 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:H/A:H CVSS Calculator
Summary
[none]
Details

Mbed TLS before 3.6.4 allows a use-after-free in certain situations of applications that are developed in accordance with the documentation. The function mbedtls_x509_string_to_names() takes a head argument that is documented as an output argument. The documentation does not suggest that the function will free that pointer; however, the function does call mbedtls_asn1_free_named_data_list() on that argument, which performs a deep free(). As a result, application code that uses this function (relying only on documented behavior) is likely to still hold pointers to the memory blocks that were freed, resulting in a high risk of use-after-free or double-free. In particular, the two sample programs x509/cert_write and x509/cert_req are affected (use-after-free if the san string contains more than one DN).

Database specific
{
    "cna_assigner":  "mitre",
    "cwe_ids":  [
        "CWE-416"
    ],
    "osv_generated_from":  "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/47xxx/CVE-2025-47917.json",
    "unresolved_ranges":  [
        {
            "extracted_events":  [
                {
                    "fixed":  "3.6.4"
                }
            ],
            "source":  "AFFECTED_FIELD"
        },
        {
            "extracted_events":  [
                {
                    "fixed":  "3.6.4"
                }
            ],
            "source":  "CPE_FIELD"
        },
        {
            "extracted_events":  [
                {
                    "fixed":  "3.6.4"
                }
            ],
            "source":  "DESCRIPTION"
        }
    ]
}
References

Affected packages

Git / github.com/Mbed-TLS/mbedtls

Affected ranges

Type
GIT
Repo
https://github.com/Mbed-TLS/mbedtls
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed
Database specific
Show details
{
    "cpe":  "cpe:2.3:a:arm:mbed_tls:*:*:*:*:*:*:*:*",
    "extracted_events":  [
        {
            "introduced":  "0"
        },
        {
            "fixed":  "3.6.4"
        }
    ],
    "source":  "CPE_RANGE"
}

Affected versions

Other
beta-oob-2
mbedos-release-15-11
mbedos-techcon-oob2
mbedtls-2.*
mbedtls-2.0.0
mbedtls-2.1.0
mbedtls-2.1.1
mbedtls-2.1.2
mbedtls-2.10.0
mbedtls-2.11.0
mbedtls-2.12.0
mbedtls-2.13.0
mbedtls-2.13.1
mbedtls-2.14.0
mbedtls-2.16.0
mbedtls-2.19.0
mbedtls-2.19.0d1
mbedtls-2.19.0d2
mbedtls-2.19.1
mbedtls-2.2.0
mbedtls-2.2.1
mbedtls-2.20.0
mbedtls-2.20.0d0
mbedtls-2.21.0
mbedtls-2.22.0d0
mbedtls-2.24.0
mbedtls-2.26.0
mbedtls-2.3.0
mbedtls-2.4.0
mbedtls-2.5.0
mbedtls-2.5.1
mbedtls-2.6.0
mbedtls-2.6.0-rc1
mbedtls-2.7.0
mbedtls-2.7.0-rc1
mbedtls-2.8.0
mbedtls-2.8.0-rc1
mbedtls-2.9.0
polarssl-1.*
polarssl-1.2.0
polarssl-1.2.1
polarssl-1.2.2
polarssl-1.2.4
polarssl-1.2.5
polarssl-1.2.6
polarssl-1.3.0
polarssl-1.3.0-rc0
polarssl-1.3.1
polarssl-1.3.2
polarssl-1.3.3
polarssl-1.3.4
polarssl-1.3.5
polarssl-1.3.6
polarssl-1.3.7
polarssl-1.3.8
polarssl-1.3.9
v2.*
v2.24.0
v2.26.0
yotta-2.*
yotta-2.3.1

Database specific

source
"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2025-47917.json"