core-rs-albatross icon indicating copy to clipboard operation
core-rs-albatross copied to clipboard

Create tests that make sure ZKP keys stay compatible

Open paberr opened this issue 7 months ago • 0 comments

The ZKP circuits require very specific serialization of the MacroBlock. In particular, it assumes the body is hashed as hash(pk_tree_root || body_bytes), where body_bytes is 64 bytes long. The header is hashed as hash(network || version || block_number || intermediate_header_bytes || body_hash || history_root) where intermediate_header_bytes is exactly 4+8+32+32+32+96+32+32=268 bytes long.

We should create tests that make sure we don't change these constraints by accident.

paberr avatar Jun 28 '24 09:06 paberr