Skip to content

Commit

Permalink
Merge pull request #1 from marioevz/fix-prague-zero-blob-check
Browse files Browse the repository at this point in the history
Fix zero-blob tx check in Prague
  • Loading branch information
spencer-tb authored Dec 5, 2024
2 parents 857c3fa + 07f4774 commit 51f5476
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 51f5476

Please sign in to comment.