Conversation
…er: accept V1 and V2 proofs Makes the verifier, the OS and the blockifier accept proof version V1 alongside V2, so proofs from the previously deployed prover stay valid while V2 rolls out. The in-repo transaction prover is unchanged and keeps producing V2 only. - Workspace: restores privacy-circuit-verify from proving-utils as the -v1 dependency, next to -v2 from proving. Purely additive: no shared dependency changes version. - starknet_proof_verifier: verify_proof dispatches V1 to the V1 circuit and V2 to the V2 circuit; V0 stays rejected. try_into_proof_facts still stamps V2, the only version built here. - Cairo OS: check_proof_facts accepts PROOF_VERSION_V1 or PROOF_VERSION_V2. Only the `os` program hash changes; regenerated. - starknet_os: restores Const::ProofVersionV1. - blockifier: allowed_proof_versions for 0.14.4 becomes [V1, V2]. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
…-v1 to an immutable rev PR #15120 added privacy-circuit-verify-v1 as a git dependency pinned by `tag = "v0.14.3-rust-bump"`. Unlike every other git dependency in the workspace (privacy-circuit-verify-v2, privacy-prove), a tag is a mutable ref: if it is later moved upstream in starkware-libs/proving-utils (deliberately or via a compromised repository), a future `cargo update` would silently swap in different code for this security-critical proof verification path, with no Cargo.toml diff for reviewers to catch. Pin it to the exact commit already resolved in Cargo.lock via `rev` instead, matching the convention used everywhere else in the file, and add a regression test asserting no git dependency uses a mutable tag or branch ref. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BXBpvrNnCRkjd35DuaUYa7
PR SummaryLow Risk Overview Adds Reviewed by Cursor Bugbot for commit ec752cb. Bugbot is set up for automated code reviews on this repo. Configure here. |
`toml_test_utils` is a workspace member crate (listed in the root Cargo.toml `members`), but it was missing from `AllowedScopes` in commitlint.config.js. The commitlint CI job validates the PR title, so the title of this PR -- "workspace,workspace_tests,toml_test_utils: pin privacy-circuit-verify-v1 to an immutable rev" -- fails with "Invalid scope(s): toml_test_utils". Register the crate as a valid scope rather than dropping it from the title: the list exists to ensure scopes name real crates, and this one does. Invalid scopes are still rejected. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BXBpvrNnCRkjd35DuaUYa7
…-curie-nb6t2t # Conflicts: # Cargo.lock # Cargo.toml
|
Artifacts upload workflows: |
|
Two CI checks failed on
Will report back if either fails again on re-run. Generated by Claude Code |
Summary
Automated security scan of #15120 (merged), which reintroduced the
privacy-circuit-verify-v1proof-verification circuit as a dependency.That dependency was added pinned by a mutable git
tag:Every other git dependency in the workspace (
privacy-circuit-verify-v2,privacy-prove) is pinned by an immutable commitrevinstead. A git tag is not immutable: it can be moved to a different commit upstream — deliberately, by mistake, or via a compromisedstarkware-libs/proving-utilsrepository — and a latercargo update -p privacy-circuit-verify-v1(or a fresh lockfile resolution) would silently pull in different code for this security-critical cryptographic proof-verification path, with no correspondingCargo.tomldiff for a reviewer to catch.Cargo.lockcurrently pins the resolved commit, but that protection only holds until the lockfile entry is next regenerated.This is a supply-chain integrity risk (OWASP A08:2021 – Software and Data Integrity Failures / CWE-829).
Changes
Cargo.toml: repinprivacy-circuit-verify-v1torev = "3035dd00421daa541894297bd754db6e2787807b"— the exact commit the tag already resolved to inCargo.lock— instead oftag = "v0.14.3-rust-bump". No code or resolved-dependency-graph change; only theCargo.locksourceURL's ref-type changes from?tag=...to?rev=....toml_test_utils: capturetag/branchfields onDependencyValue::Objectso the workspace-lint tests can see them.workspace_tests: addtest_git_dependencies_pinned_to_immutable_rev, asserting no workspace git dependency is pinned by a mutabletag/branchref. Verified this test fails (namingprivacy-circuit-verify-v1) against the pre-fixCargo.toml, and passes after the fix.Testing
cargo test -p workspace_tests: 18/18 pass (new test included).cargo metadata --locked: succeeds against the updatedCargo.lock, confirming the lockfile is still consistent withCargo.toml.scripts/rust_fmt.shandcargo clippy -p workspace_tests -p toml_test_utils --all-targets -- -D warnings: clean.tag-pinnedCargo.toml, and passes after repinning torev.🤖 Generated with Claude Code
https://claude.ai/code/session_01BXBpvrNnCRkjd35DuaUYa7
Generated by Claude Code