Check the payload block hash rule on live nodes before gloas refuses

Đang mở
#818 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 6 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
rust
Lĩnh vực
backend, observability

Hướng nghiên cứu

Start with crates/net/p2p/src/beacon/payload_hash.rs and docs/spec_deviations.md; review the existing counters and ignored payload_hash::tests::verify_block_cost test. After deployment, track mismatch and validation overload metrics across the named networks for several days, measure worst case peak memory, and verify final header fields and the envelope counter on Platåberget before changing envelope_verdict to refuse mismatches.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

lambdaclass/ethlambda#770 added a rule the consensus specification does not have: beacon p2p rebuilds the execution header from a payload's fields and compares keccak256(rlp(header)) with its block_hash (crates/net/p2p/src/beacon/payload_hash.rs). A pre-gloas gossip block that does not match is IGNOREd. A gloas envelope is only counted and logged, because the Amsterdam header may still change. The PR pinned the encoding with real-chain vectors per fork and a local check over 200 mainnet blocks, but nothing on a running node, which is out of a code review's scope.

What to measure once it is deployed:

  • lean_beacon_payload_block_hash_mismatch_total{kind} on the mainnet, Hoodi, Sepolia and Platåberget followers: it should stay at zero for several days. A non-zero block count means honest blocks are being dropped from gossip. A non-zero envelope count means the gloas encoding is off.
  • Validation-permit saturation on beacon_block: the rate of lean_beacon_gossip_validation_total{kind="beacon_block",reason="overloaded"} before and after. The hash runs inside a gossip_validation_permits permit (about 0.24 ms for a 238-transaction mainnet block, up to 0.6 s for the worst-case block at the size limit; see docs/spec_deviations.md).
  • Peak memory of the worst case (1,048,576 tiny transactions, each copied into the trie). It was not measured; the ignored payload_hash::tests::verify_block_cost could measure it locally.

Before gloas refuses on a mismatch (envelope_verdict in payload_hash.rs):

  • re-pin block_access_list_hash and slot_number against the final EIP-7928 and EIP-7843 header, with a real envelope from a network on the final header;
  • check the envelope counter has stayed at zero on Platåberget.

Refusing would then mean turning envelope_verdict into the same Ignore(PayloadBlockHashMismatch) path block_verdict uses.

Ngôn ngữ chính
Rust
Star
86
Fork
34
Merge trung bình
9 ngày 20 giờ
Pull request đã merge (30 ngày)
77

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của lambdaclass/ethlambda

Tất cả issue của lambdaclass/ethlambda

Issue tương tự

Thêm issue về Rust

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.