python: signature verification can never succeed for Python 3.14+
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 52/100
Hướng nghiên cứu
Start in src/python/install.sh around lines 532-591, where the cosign and signature downloads run. Reproduce the curl exit code 2 from -f combined with --fail-with-body, then check the .sigstore URL that python.org serves for 3.14+. Done means the downloads succeed, cosign verify-blob checks the bundle against the signer identity python.org lists, and a failed check stops the build or logs a real error.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Summary
In the python feature (1.8.0, and src/python/install.sh on main), the cosign check for Python 3.14+ always fails, so these versions are always built from source without signature verification. The build continues and logs that this is expected for newly released versions, but it happens for every version.
Causes
-
Invalid curl flags. The cosign and signature downloads (lines 532, 544, 585, 591) pass both
-fand--fail-with-body, which curl rejects with exit code 2. Most of these calls send stderr to/dev/null, and none of them surfaces the real error, so it looks like a failed download.curl -L -f --fail-with-body https://www.python.org/ftp/python/3.14.10/Python-3.14.10.tgz.crt -o /dev/null # curl: option --fail-with-body: is badly used here # exit code 2Reproduced with curl 8.14.1 (in a dev container built from
mcr.microsoft.com/devcontainers/base:debian) and curl 8.7.1 (macOS). With--fail-with-bodyalone, the same request exits 0. -
Wrong certificate URL. Lines 580-581 look for
.sigand.pem. For 3.14.10, python.org returns 200 for.sig,.crtand.sigstore, and 404 for.pem. Fixing the curl flags alone would still fail at this step. -
Any signer is accepted. The
cosign verify-blobcall uses--certificate-identity-regexp=".*"and--certificate-oidc-issuer-regexp=".*". Even a passing check wouldn't show that the Python release manager signed the file. -
The build continues after a failed check. If verification fails, the script logs a warning and builds the tarball anyway, and there is no checksum check. The warning says this is "expected for newly released versions where cosign signatures are not yet available", which hides the failure.
Impact
Every Python 3.14+ build from source through this feature skips signature verification. The tarball is still downloaded over HTTPS, so this doesn't create an attack by itself, but the protection that replaced PGP for 3.14+ isn't working.
Suggested fix
-
Remove
-ffrom the affected curl calls. -
Verify with the
.sigstorebundle and the signer identity that python.org lists for each release series. This command returnedVerified OKfor 3.14.10 with cosign 3.1.4, and failed when given a different identity:cosign verify-blob \ --bundle Python-3.14.10.tgz.sigstore \ --certificate-identity [email protected] \ --certificate-oidc-issuer https://github.com/login/oauth \ Python-3.14.10.tgz -
Consider failing the build when verification fails, or at least changing the warning so it doesn't describe a failure as expected.
- Ngôn ngữ chính
- Shell
- Star
- 1.6k
- Fork
- 628
- Merge trung bình
- 1 ngày 19 giờ
- Pull request đã merge (30 ngày)
- 5
Chuẩn bị môi trường
Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của devcontainers/features
-
Terraform feature fails to install due to tflint checksumCó thể đã có người làm @v-Kaniska244 đã nhận 4 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
devcontainers/features#1757 · 1 bình luận · 1 reaction · 2 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
docker-outside-of-docker: processes started before the entrypoint's `groupmod` keep stale groups and cannot use the socketCó thể đã có người làm Có pull request liên kết đang mở hoặc đã được merge. Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 18/100
devcontainers/features#1760 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Can the onCreateCommand be run background and use the Output tab instead of the Terminal tab?Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 38/100
devcontainers/features#1754 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
use mise for java feature installation or make sdkman configuable to download JDK from mirrosĐang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
devcontainers/features#1730 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Version resolution over unauthenticated git makes feature installs fail hard, with no fallbackCó thể đã có người làm @v-Kaniska244 đã nhận 57 ngày trước. Đang mở
devcontainers/features#1726 · 2 bình luận · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của devcontainers/features
Issue tương tự
-
lesson-submission pending-review
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Ikalus1988/MisakaNet#4393 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
ai-driven-fuzzing bug claude Minor
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
linagora/open-bastion#425 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
BUG
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 90/100
linuxmint/cinnamon-spices-applets#9223 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
leanprover-community/lean4game#589 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
nolabs-ai/nono-packs#65 ·