Skip to content

feat: check_branch_node and check_extension_node should check that embedded nodes have valid size #1376

@Eikix

Description

@Eikix

Why

In a valid MPT, embedded nodes are such that their RLP encoding's length is strictly less than 32.

What

Add a check in check_branch_node and check_extension_node such if a subnode is embedded, then its RLP encoding size must be less than 32.

How

For each embedded subnode, RLP encode it and assert the resulting byte len is less than 32.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    Status

    Done

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions