Skip to content

apollo_starknet_os_program,starknet_os: gate OS contract-address derivation on Blake2 flag#14542

Closed
ron-starkware wants to merge 1 commit into
ron/address-derivation/select-hash-from-vcfrom
ron/address-derivation/os-blake-derivation
Closed

apollo_starknet_os_program,starknet_os: gate OS contract-address derivation on Blake2 flag#14542
ron-starkware wants to merge 1 commit into
ron/address-derivation/select-hash-from-vcfrom
ron/address-derivation/os-blake-derivation

Conversation

@ron-starkware

Copy link
Copy Markdown
Contributor

Add get_contract_address_blake (optimized Blake2s via hash_state_blake) and a
get_contract_address_with_hash wrapper, and gate both deploy syscalls on a new
use_blake_address_derivation flag, plumbed from OsHintsConfig through a hint into
BlockContext. The flag defaults to false (Pedersen), so this is behavior-preserving.
Regenerates os_resources, constants.cairo, the program hash, and hint-coverage
snapshots for the runtime-charged +15-step deploy overhead, and adds a Cairo<->Rust
parity test for the Blake2 derivation.

Co-Authored-By: Claude Opus 4.8 (1M context) noreply@anthropic.com

…vation on Blake2 flag

Add get_contract_address_blake (optimized Blake2s via hash_state_blake) and a
get_contract_address_with_hash wrapper, and gate both deploy syscalls on a new
use_blake_address_derivation flag, plumbed from OsHintsConfig through a hint into
BlockContext. The flag defaults to false (Pedersen), so this is behavior-preserving.
Regenerates os_resources, constants.cairo, the program hash, and hint-coverage
snapshots for the runtime-charged +15-step deploy overhead, and adds a Cairo<->Rust
parity test for the Blake2 derivation.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@reviewable-StarkWare

Copy link
Copy Markdown

This change is Reviewable

@ron-starkware

Copy link
Copy Markdown
Contributor Author

Superseded by the version-gating rework. This flag-based step was folded into a 2-PR version-based stack: #14539 (starknet_api foundation) + #14547 (activation at StarknetVersion 0.14.4). The runtime use_blake_address_derivation versioned constant was dropped in favor of pure version-gating (mirroring the 0.14.3 OS-config-hash Blake migration); see docs/blake2_address_derivation_migration.md §3 & §5. Closing.

@ron-starkware ron-starkware deleted the ron/address-derivation/os-blake-derivation branch June 17, 2026 22:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants