apollo_starknet_os_program: restore keccak syscall in virtual OS#14071
Conversation
PR SummaryMedium Risk Overview Bumps the virtual OS program hash everywhere it’s pinned/validated ( Adjusts virtual-OS security tests to reflect that Reviewed by Cursor Bugbot for commit cec96b1. Bugbot is set up for automated code reviews on this repo. Configure here. |
b862e02 to
44e99e0
Compare
3210a0e to
5d66a74
Compare
44e99e0 to
ba1f90d
Compare
5d66a74 to
b22c491
Compare
ba1f90d to
1ac2afb
Compare
b22c491 to
ac8abb5
Compare
de06d14 to
c95aeed
Compare
ac8abb5 to
375c852
Compare
b1beaab to
7b6c094
Compare
6c65407 to
6a5b663
Compare
7b6c094 to
4377e32
Compare
AvivYossef-starkware
left a comment
There was a problem hiding this comment.
@AvivYossef-starkware reviewed 6 files and all commit messages, and made 1 comment.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on Yoni-Starkware).
Cargo.toml line 337 at r1 (raw file):
pretty_assertions = "1.4.0" primitive-types = "0.12.1" privacy-circuit-verify = { git = "https://github.com/Yoni-Starkware/proving-utils", rev = "95bc227" }
consider adding v1 to be consistent with ProofVersion enum
Code quote:
privacy-circuit-verify
AvivYossef-starkware
left a comment
There was a problem hiding this comment.
Where does it "Re-adds the keccak syscall to the virtual OS"? The PR description/name is misleading
@AvivYossef-starkware made 1 comment.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on Yoni-Starkware).
Yoni-Starkware
left a comment
There was a problem hiding this comment.
In the beginning, the virtual OS contained keccak
@Yoni-Starkware made 1 comment.
Reviewable status: 0 of 15 files reviewed, all discussions resolved (waiting on AvivYossef-starkware).
4377e32 to
c086c43
Compare
e71dabc to
f9e3866
Compare
c086c43 to
e7dede0
Compare
f9e3866 to
a3b9278
Compare
Yoni-Starkware
left a comment
There was a problem hiding this comment.
@Yoni-Starkware made 1 comment.
Reviewable status: 0 of 15 files reviewed, all discussions resolved (waiting on AvivYossef-starkware).
Cargo.toml line 337 at r1 (raw file):
Previously, AvivYossef-starkware wrote…
consider adding v1 to be consistent with ProofVersion enum
Done in prev PR
e7dede0 to
429d431
Compare
62375eb to
a69b2b8
Compare
429d431 to
cc8b12d
Compare
a69b2b8 to
473e4be
Compare
cc8b12d to
e9aef6a
Compare
473e4be to
3da1bb0
Compare
e9aef6a to
a6beb27
Compare
3da1bb0 to
487d287
Compare
a6beb27 to
aff094e
Compare
487d287 to
4070973
Compare
Re-adds the keccak syscall to the virtual OS (reverts the removal from #12355) and bumps allowed_virtual_os_program_hashes to the new virtual_os program hash. Cleans up the now-redundant 'Keccak' arm in test_contract's test_forbidden_syscall_in_virtual_mode and drops the corresponding case in test_forbidden_syscall. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
4070973 to
cec96b1
Compare
Yoni-Starkware
left a comment
There was a problem hiding this comment.
@Yoni-Starkware reviewed 17 files and all commit messages.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on Yoni-Starkware).
Stack:
Summary
keccaksyscall to the virtual OS — reverts the removal from apollo_starknet_os_program: remove keccak syscall from virtual OS #12355. TheKECCAK_SELECTORarm is restored inexecute_syscalls__virtual.cairoso virtual-OS proofs can again contain transactions that call the keccak syscall.allowed_virtual_os_program_hashesentry (inblockifier_versioned_constants_0_14_3.jsonandconstants.cairo) to the new virtual OS program hash, replacing the previous keccak-disabled hash.Keccakarm intest_contract::test_forbidden_syscall_in_virtual_modeand the corresponding rstest case invirtual_os_test::test_forbidden_syscall.serialize_call("test_keccak", &[])line inprove_and_verify_multicall_tx(added by stacked PR starknet_os_flow_tests: add multicall prove test; drop balance_of test #14082) so the multicall test now exercises the keccak syscall path via the virtual OS.Auto-regenerated fixtures:
program_hash.jsonvirtual_os hashversioned_constants_diff_regression/0.14.2_0.14.3.txtbouncer_test::class_hash_migration_data_from_stateexpected sierra/proving gasstack_trace_regression/test_contract_ctor_frame_stack_trace_cairo1_casm.txtTest plan
cargo test -p apollo_starknet_os_program test_program_hashes(withUPDATE_EXPECT=1)cargo test -p apollo_starknet_os_program test_os_constants(withUPDATE_EXPECT=1)cargo test -p starknet_os test_virtual_os_program_hash_is_allowedcargo test -p blockifier test_vc_diffs_regression(withUPDATE_EXPECT=1)cargo test -p blockifier --lib bouncer::(regen'd snapshots)cargo test -p starknet_os_flow_tests virtual_os_test::test_basic_happy_flowcargo test -p starknet_os_flow_tests virtual_os_test::test_forbidden_syscall(remaining cases pass)prove_and_verify_multicall_tx -- --ignored(requires--features starknet_transaction_prover/stwo_proving --release+ nightly)