diff --git a/core/types/block.go b/core/types/block.go index d189c86c2..360f1eb47 100644 --- a/core/types/block.go +++ b/core/types/block.go @@ -129,6 +129,11 @@ func (h *Header) SanityCheck() error { if eLen := len(h.Extra); eLen > 100*1024 { return fmt.Errorf("too large block extradata: size %d", eLen) } + if h.BaseFee != nil { + if bfLen := h.BaseFee.BitLen(); bfLen > 256 { + return fmt.Errorf("too large base fee: bitlen %d", bfLen) + } + } return nil }