pillow@10.0.0 vulnerabilities

Python Imaging Library (Fork)

  • latest version

    11.2.1

  • latest non vulnerable version

  • first published

    14 years ago

  • latest version published

    9 days ago

  • licenses detected

  • Direct Vulnerabilities

    Known vulnerabilities in the pillow package. This does not include vulnerabilities belonging to this package’s dependencies.

    How to fix?

    Automatically find and fix vulnerabilities affecting your projects. Snyk scans for vulnerabilities and provides fixes for free.

    Fix for free
    VulnerabilityVulnerable Version
    • H
    Buffer Overflow

    Affected versions of this package are vulnerable to Buffer Overflow via the strcpy function in _imagingcms.c, due to two calls that were able to copy too much data into fixed length strings.

    How to fix Buffer Overflow?

    Upgrade pillow to version 10.3.0 or higher.

    [,10.3.0)
    • H
    Denial of Service (DoS)

    Affected versions of this package are vulnerable to Denial of Service (DoS) when using arbitrary strings as text input and the number of characters passed into PIL.ImageFont.ImageFont.getmask() is over a certain limit. This can lead to a system crash.

    How to fix Denial of Service (DoS)?

    Upgrade pillow to version 10.2.0 or higher.

    [,10.2.0)
    • H
    Denial of Service (DoS)

    Affected versions of this package are vulnerable to Denial of Service (DoS) if the size of individual glyphs extends beyond the bitmap image, when using PIL.ImageFont.ImageFont function. Exploiting this vulnerability could lead to a system crash.

    How to fix Denial of Service (DoS)?

    Upgrade pillow to version 10.2.0 or higher.

    [,10.2.0)
    • H
    Eval Injection

    Affected versions of this package are vulnerable to Eval Injection via the PIL.ImageMath.eval function when an attacker has control over the keys passed to the environment argument.

    How to fix Eval Injection?

    Upgrade pillow to version 10.2.0 or higher.

    [,10.2.0)
    • C
    Heap-based Buffer Overflow

    Pillow is a PIL (Python Imaging Library) fork.

    Affected versions of this package are vulnerable to Heap-based Buffer Overflow when the ReadHuffmanCodes() function is used. An attacker can craft a special WebP lossless file that triggers the ReadHuffmanCodes() function to allocate the HuffmanCode buffer with a size that comes from an array of precomputed sizes: kTableSize. The color_cache_bits value defines which size to use. The kTableSize array only takes into account sizes for 8-bit first-level table lookups but not second-level table lookups. libwebp allows codes that are up to 15-bit (MAX_ALLOWED_CODE_LENGTH). When BuildHuffmanTable() attempts to fill the second-level tables it may write data out-of-bounds. The OOB write to the undersized array happens in ReplicateValue.

    Notes:

    This is only exploitable if the color_cache_bits value defines which size to use.

    This vulnerability was also published on libwebp CVE-2023-5129

    Changelog:

    2023-09-12: Initial advisory publication

    2023-09-27: Advisory details updated, including CVSS, references

    2023-09-27: CVE-2023-5129 rejected as a duplicate of CVE-2023-4863

    2023-09-28: Research and addition of additional affected libraries

    2024-01-28: Additional fix information

    How to fix Heap-based Buffer Overflow?

    Upgrade Pillow to version 10.0.1 or higher.

    [,10.0.1)