File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
beacon_chain/gossip_processing Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -598,6 +598,12 @@ proc validateDataColumnSidecar*(
598598 if v.isErr:
599599 return dag.checkedReject (v.error)
600600
601+ # Check if the sidecar respects the blob limit.
602+ let epoch = block_header.slot.epoch ()
603+ if lenu64 (data_column_sidecar.kzg_commitments) >
604+ dag.cfg.get_blob_parameters (epoch).MAX_BLOBS_PER_BLOCK :
605+ return dag.checkedReject (" DataColumnSidecar: The sidecar does not respect the blob limit" )
606+
601607 # [REJECT] The sidecar is for the correct subnet
602608 # -- i.e. `compute_subnet_for_data_column_sidecar(blob_sidecar.index) == subnet_id`.
603609 if not (compute_subnet_for_data_column_sidecar (data_column_sidecar.index) == subnet_id):
@@ -723,7 +729,6 @@ proc validateDataColumnSidecar*(
723729 data_column_sidecar: gloas.DataColumnSidecar ,
724730 wallTime: BeaconTime , subnet_id: uint64 ):
725731 Result [void , ValidationError ] =
726-
727732 # [REJECT] The sidecar is valid as verified by verify_data_column_sidecar
728733 block :
729734 let v = verify_data_column_sidecar (data_column_sidecar)
You can’t perform that action at this time.
0 commit comments