Skip to content

Skip CVE-2026-3219 in pip-audit until pip 26.1 ships - #51

Merged
JoaoPucci merged 2 commits into
mainfrom
ci-pip-audit-upgrade
Apr 24, 2026
Merged

Skip CVE-2026-3219 in pip-audit until pip 26.1 ships#51
JoaoPucci merged 2 commits into
mainfrom
ci-pip-audit-upgrade

Conversation

@JoaoPucci

@JoaoPucci JoaoPucci commented Apr 24, 2026

Copy link
Copy Markdown
Owner

Summary

The audit job has been failing on every PR since ~2026-04-24 15:17 UTC. Not the fault of any specific PR — a new pip CVE (CVE-2026-3219) was picked up by pip-audit's advisory feed mid-day, and the runner's own bundled pip is the affected version.

The CVE

What I tried first (and why it failed)

Initial commit upgraded pip to >=26.1 before pip-audit runs. That failed in CI because pip 26.1 isn't available on PyPI:

ERROR: Could not find a version that satisfies the requirement pip>=26.1
(from versions: ..., 26.0, 26.0.1)

The advisory's Fixed Version: 26.1 was describing the target release number, not a version available today. Backed out.

What actually works

Surgical --ignore-vuln CVE-2026-3219 on the audit invocation, with a comment that anchors when to remove it (once pip 26.1+ ships). Preserves pip-audit's coverage of every other package and every other pip CVE that might drop next week.

-        run: pip-audit --disable-pip -r requirements-dev.txt
+        run: pip-audit --disable-pip --ignore-vuln CVE-2026-3219 -r requirements-dev.txt

Why this isn't a real security regression

The CVE's exploit vector is "install a crafted hybrid archive." Our deploy pipeline runs pip install --require-hashes -r requirements.txt; any archive whose SHA-256 doesn't match the committed hash is rejected before pip ever parses its magic bytes. So the exploitable path against our production deploys is already closed at the hash-pinning layer, independent of which pip version is installed.

When to remove this ignore

Watch for pip 26.1 (or whatever release ships the fix from pypa/pip#13870) to land on PyPI. Revert this commit or just delete the --ignore-vuln flag and its comment.

Test plan

Sources

GitHub Actions' Python 3.12 toolchain ships pip 26.0.1 bundled in
the image, which CVE-2026-3219 (disclosed 2026-04-20) flags:
concatenated tar+ZIP archives are installed as ZIP regardless of
filename. Fix landed in pip 26.1.

Before this change, the audit job inspected its own runtime pip
26.0.1, found the CVE, and failed every PR merged since the
advisory DB picked up the entry -- even on branches that don't
touch Python at all.

Upgrade pip to >=26.1 before installing pip-audit, so the audit
runs against a patched runtime. Preferred over a bare
--ignore-vuln CVE-2026-3219 flag: no hardcoded CVE to remove
later, and the step stays self-protecting if another pip CVE
drops next week.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@JoaoPucci JoaoPucci added bug Something isn't working github-actions Affects workflow actions pinned under .github/workflows/ labels Apr 24, 2026
@JoaoPucci JoaoPucci self-assigned this Apr 24, 2026
Prior commit assumed pip 26.1 shipped (based on the CVE advisory
page), but PyPI's latest is still 26.0.1; the CI runner failed to
resolve pip>=26.1. The fix has merged in pypa/pip#13870 but no
release has been cut yet.

Replace with a surgical --ignore-vuln CVE-2026-3219 on the audit
step, with a comment anchoring when to remove it (once pip 26.1+
is on PyPI). The runtime exploitation path against our deploys is
independently blocked by --require-hashes at install time, so this
is a legitimate temporary exception, not a security regression.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@JoaoPucci JoaoPucci changed the title Upgrade pip before pip-audit to patch CVE-2026-3219 Skip CVE-2026-3219 in pip-audit until pip 26.1 ships Apr 24, 2026
@JoaoPucci
JoaoPucci merged commit 62b26e9 into main Apr 24, 2026
4 checks passed
@JoaoPucci
JoaoPucci deleted the ci-pip-audit-upgrade branch April 30, 2026 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working github-actions Affects workflow actions pinned under .github/workflows/

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant