-
Notifications
You must be signed in to change notification settings - Fork 249
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
update Deneb for blob sidecar inclusion proofs #5565
Conversation
`BlobSidecar` is no longer signed, instead use Merkle proof to link blobs with block. - ethereum/consensus-specs#3531 Associated beacon-API / builder-specs still TBD; minimal changes done to compile in similar style to previous spec, but not standardized yet. - ethereum/beacon-APIs#369 - ethereum/builder-specs#90
411bfde
to
9cc745a
Compare
998d1db
to
a48ca2b
Compare
# [REJECT] The sidecar's blob is valid as verified by `verify_blob_kzg_proof( | ||
# blob_sidecar.blob, blob_sidecar.kzg_commitment, blob_sidecar.kzg_proof)`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Double-checked with @mratsim , the proposer sig check is the faster one, so doing it before the KZG check: "pairings are 2 levels deep in KZG and 1 deep in BLS signature (just after deserialization and sanity checks that points are on curve and non-infinity)"
Batching of the two verifications would be clunky, likely not worth it.
kzg_proofs: blobsBundle.proofs, | ||
blobs: blobsBundle.blobs) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sidecars are no longer sent back and forth, as they no longer need a signature. Instead, just the kzg_proofs
and blobs
are sent.
kzg_proofs
and blobs
are downloaded by the VC and then submitted again to the BN to support use case where the block is produced by a different BN than the one who is broadcasting. The BN then converts the SignedDenebBlockContents
to SignedBeaconBlock
+ BlobSidecar
list
KzgProofs* = List[KzgProof, Limit MAX_BLOB_COMMITMENTS_PER_BLOCK] | ||
Blobs* = List[Blob, Limit MAX_BLOB_COMMITMENTS_PER_BLOCK] | ||
BlobRoots* = List[Eth2Digest, Limit MAX_BLOB_COMMITMENTS_PER_BLOCK] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure where to put them and what to put as the correct limit. beacon-API uses 0 .. MAX_BLOBS_PER_BLOCK in informal metadata description, builder-API uses MAX_BLOB_COMMITMENTS_PER_BLOCK in a more explicit specification. In practice, it doesn't matter as the SSZ messages are not hash-tree-rooted in neither of the two protocols. If they were hash_tree_rooted, using the theoretical capacity (MAX_BLOB_COMMITMENTS_PER_BLOCK) makes more sense (that is also what they use for the KzgCommitments inside consensus, where HTR matters).
@@ -69,25 +69,18 @@ type | |||
|
|||
# https://github.com/ethereum/builder-specs/blob/534e4f81276b8346d785ed9aba12c4c74b927ec6/specs/deneb/builder.md#blindedblobsidecar | |||
BlindedBlobSidecar* = object | |||
block_root*: Eth2Digest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
BlindedBlobSidecar
may go away entirely, but the specs are still in flux:
For now, have done the minimal changes to it to make the flow work in theory, but the spec may optimize further and get rid of the BlindedBlobSidecar
altogether.
This should be all that's needed to get us going with the new blob sidecar flavor, as an initial PR upgrading to v1.4.0-beta.4 test vectors.
Notably missing:
|
BlobSidecar
is no longer signed, instead use Merkle proof to link blobs with block.Associated beacon-API / builder-specs still TBD; minimal changes done to compile in similar style to previous spec, but not standardized yet.