通过 Cosign 工具进行签名验证:
- 下载发布文件(如
checksums.txt
)及其签名文件(.sig
和.pem
) - 运行验证命令:
cosign verify-blob --certificate-identity 'https://github.com/charmbracelet/meta/.github/workflows/goreleaser.yml@refs/heads/main' --certificate-oidc-issuer 'https://token.actions.githubusercontent.com' --cert checksums.txt.pem --signature checksums.txt.sig ./checksums.txt
- 若输出
Verified OK
表示文件未被篡改
该验证机制采用 GitHub Actions 的 OIDC 令牌,确保证书链来自可信构建流程。
本答案来源于文章《Crush:终端AI编程助手,集成LSP与多模型切换》