CURL-CVE-2016-8618

    Dashboard / Vulnerabilities / CURL-CVE-2016-8618

    CURL-CVE-2016-8618

    Published: 2 Nov 2016Last Modified: 27 Oct 2026
    Aliases:

    Summary: double free in curl_maprintf

    Details: The libcurl API function called `curl_maprintf()` can be tricked into doing a double free due to an unsafe `size_t` multiplication, on systems using 32-bit `size_t` variables. The function is also used internally in numerous situations. The function doubles an allocated memory area with realloc() and allows the size to wrap and become zero and when doing so realloc() returns NULL *and* frees the memory - in contrary to normal realloc() fails where it only returns NULL - causing libcurl to free the memory *again* in the error path. Systems with 64-bit versions of the `size_t` type are not affected by this issue. This behavior can be triggered using the publicly exposed function.

    References:

    Affected packages

    Package

    Name:

    Purl:

    Affected ranges

    Type: SEMVER

    Events:

    Introduced- 5.4
    Fixed -7.51.0

    Affected versions

    7.50.3
    7.50.2
    7.50.1
    7.50.0

    Common Vulnerability Scoring System

    Attack Vector
    Network
    Adjacent
    Local
    Physical
    Privileges Required
    None
    Low
    High
    User Interaction
    None
    Required
    Scope
    Unchanged
    Changed
    Confidentiality
    None
    Low
    High
    Integrity
    None
    Low
    High
    Availability
    None
    Low
    High