Skip to content

Memory exhaustion via crafted zip file #156002

Closed

Activity

  1. encukou commented on Sep 8, 2026

    @encukou
    MemberAuthor

    Happy to open a PR if you want.

    Please do. Thank you for the offer!

    (Ideally add a default arg to _decompressor_needs_input; using None/True/False for 3 states tends to get messy.)

    I realize that _get_decompressor() is private, but this seems to be the standard method to extend zipfile

    Not sure what you mean by “standard”. This kind of breakage is exactly what you should expect when monkey-patching private functions. Which doesn't mean we can't fix things when alerted, of course.

    A better fix would be adding some registration API -- see #113767.

  2. rasmusfaber commented on Sep 8, 2026

    @rasmusfaber
    Contributor

    Please do. Thank you for the offer!

    Here you go: #157180

    Not sure what you mean by “standard”. This kind of breakage is exactly what you should expect when monkey-patching private functions. Which doesn't mean we can't fix things when alerted, of course.

    Ah, perhaps I should have said "the approach that third-part decompressor implementations have converged on". I totally agree that no promises were made not to break this approach.

    A better fix would be adding some registration API -- see #113767.

    Yes. When the eco-system starts to use hacks to extend, and those hacks starts to break, that is usually a smell that there need to be a standard plugin API.

  3. added a commit that references this issue on Sep 10, 2026
  4. added a commit that references this issue on Sep 12, 2026
  5. added a commit that references this issue on Sep 14, 2026
  6. added a commit that references this issue on Sep 15, 2026
  7. added 5 commits that reference this issue on Sep 16, 2026
  8. added 2 commits that reference this issue on Sep 29, 2026
  9. added 2 commits that reference this issue on Oct 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.10 (EOL)end of life3.11only security fixes3.12only security fixes3.13only security fixes3.14bugs and security fixes3.15bugs and security fixes3.16new features, bugs and security fixesstdlibStandard Library Python modules in the Lib/ directorytype-securityA security issue

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions