Skip to content

Commit

Permalink
Fix zero-blob tx check in Prague
Browse files Browse the repository at this point in the history
  • Loading branch information
marioevz committed Dec 4, 2024
1 parent 857c3fa commit 07f4774
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/ethereum/prague/fork.py
Original file line number Diff line number Diff line change
Expand Up @@ -430,6 +430,10 @@ def check_transaction(
max_gas_fee = tx.gas * tx.gas_price

if isinstance(tx, BlobTransaction):
if not isinstance(tx.to, Address):
raise InvalidBlock
if len(tx.blob_versioned_hashes) == 0:
raise InvalidBlock
for blob_versioned_hash in tx.blob_versioned_hashes:
if blob_versioned_hash[0:1] != VERSIONED_HASH_VERSION_KZG:
raise InvalidBlock
Expand Down

0 comments on commit 07f4774

Please sign in to comment.