test_bal_invalid_phantom_read_on_selfdestruct()¶
Documentation for tests/amsterdam/eip7928_block_level_access_lists/test_block_access_lists_invalid.py::test_bal_invalid_phantom_read_on_selfdestruct@636b5f17.
Generate fixtures for these test cases for Bogota with:
fill -v tests/amsterdam/eip7928_block_level_access_lists/test_block_access_lists_invalid.py::test_bal_invalid_phantom_read_on_selfdestruct --fork Bogota
Test that clients reject a BAL with a phantom storage read for an account created and destroyed within the same transaction.
A contract-creation transaction's init code immediately SELFDESTRUCTs, sending its endowment to beneficiary, without ever returning runtime code. Per EIP-6780 the created account is created and destroyed within the same transaction, so it has zero net BAL changes (its balance and code never persist), but the account still legitimately appears in the BAL as an entry with empty changes. The BAL is corrupted by injecting a phantom storage read for a slot the account never touched.
Source code in tests/amsterdam/eip7928_block_level_access_lists/test_block_access_lists_invalid.py
2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 | |
Parametrized Test Cases¶
This test generates 1 parametrized test case across 2 forks.