← Winnitude! Search  ·  Reader Mode (2096 ms)
Links: Stay in Reader Retro Site Converter Retro Mode: OFF Original Page ↗
GITHUB · 36 LINKS

Memory exhaustion via crafted zip file · Issue #156002 · python/cpython

Repository navigation

Memory exhaustion via crafted zip file  #156002


New issue

New issue

Closed

Closed
Memory exhaustion via crafted zip file #156002 Labels
3.10 (EOL)

3.11

3.12

3.13

3.14

3.15

3.16

stdlib

type-security

Description

@encukou's profile encukou opened on Aug 18, 2026

As reported by @tonghuaroot :

zipfile.ZipExtFile._read1() bounds the output of each decompress() call for DEFLATE members (it passes a max_length to zlib), but for bzip2 / LZMA / Zstandard members it called self._decompressor.decompress(data) with no bound . A whole compressed chunk was therefore expanded into a single allocation before the data = data[:self._left] clip ran.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels


    3.10 (EOL)

    3.11

    3.12

    3.13

    3.14

    3.15

    3.16

    stdlib

    type-security

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions