Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[3.14] gh-72680: Fix false positives when using zipfile.is_zipfile() (GH-134250)#134401

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
gpshead merged 1 commit intopython:3.14frommiss-islington:backport-1298511-3.14
May 21, 2025

Conversation

miss-islington
Copy link
Contributor

@miss-islingtonmiss-islington commentedMay 21, 2025
edited by bedevere-appbot
Loading

bpo-28494: Improve zipfile.is_zipfile reliability

The zipfile.is_zipfile function would only search for the EndOfZipfile
section header. This failed to correctly identify non-zipfiles that
contained this header. Now the zipfile.is_zipfile function verifies
the first central directory entry.

Changes:

  • Extended zipfile.is_zipfile to verify zipfile catalog
  • Added tests to validate failure of binary non-zipfiles
  • Reuse 'concat' handling for is_zipfile
    (cherry picked from commit1298511)

Co-authored-by: Tim Hatchtimhatch@netflix.com
Co-authored-by: John Jollyjohn.jolly@gmail.com

…ythonGH-134250)bpo-28494: Improve zipfile.is_zipfile reliabilityThe zipfile.is_zipfile function would only search for the EndOfZipfilesection header. This failed to correctly identify non-zipfiles thatcontained this header. Now the zipfile.is_zipfile function verifiesthe first central directory entry.Changes:* Extended zipfile.is_zipfile to verify zipfile catalog* Added tests to validate failure of binary non-zipfiles* Reuse 'concat' handling for is_zipfile(cherry picked from commit1298511)Co-authored-by: Tim Hatch <timhatch@netflix.com>Co-authored-by: John Jolly <john.jolly@gmail.com>
@bedevere-appbedevere-appbot mentioned this pull requestMay 21, 2025
@gpsheadgpshead self-assigned thisMay 21, 2025
@gpsheadgpsheadenabled auto-merge (squash)May 21, 2025 01:33
@gpsheadgpshead merged commitaf428a3 intopython:3.14May 21, 2025
45 checks passed
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees

@gpsheadgpshead

Labels
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@miss-islington@gpshead@thatch

[8]ページ先頭

©2009-2025 Movatter.jp