Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

new(tests): CALLF with truncated immediate bytes #1114

Merged
merged 1 commit into from
Jan 24, 2025

Conversation

chfast
Copy link
Member

@chfast chfast commented Jan 23, 2025

πŸ—’οΈ Description

πŸ”— Related Issues

βœ… Checklist

  • All: Set appropriate labels for the changes.
  • All: Considered squashing commits to improve commit history.
  • All: Added an entry to CHANGELOG.md.
  • All: Considered updating the online docs in the ./docs/ directory.
  • Tests: All converted JSON/YML tests from ethereum/tests have been added to converted-ethereum-tests.txt.
  • Tests: A PR with removal of converted JSON/YML tests from ethereum/tests have been opened.
  • Tests: Included the type and version of evm t8n tool used to locally execute test cases: e.g., ref with commit hash or geth 1.13.1-stable-3f40e65.
  • Tests: Ran mkdocs serve locally and verified the auto-generated docs for new tests in the Test Case Reference are correctly formatted.

@chfast chfast requested review from gumb0 and pdobacz January 23, 2025 15:13
Copy link
Collaborator

@pdobacz pdobacz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can also repeat the imm_from_next_section case with a byte in the data section - even better if it's the data section of the parent container, not unlike the bug which Danno's fuzzing found recently.

But maybe that would be too much

@chfast chfast requested a review from marioevz January 23, 2025 15:54
@chfast
Copy link
Member Author

chfast commented Jan 23, 2025

Adding raw bytes to bytecode strikes back. I need to check what is the best solution so far.

@chfast chfast marked this pull request as draft January 23, 2025 21:24
@chfast chfast marked this pull request as ready for review January 24, 2025 11:37
@chfast
Copy link
Member Author

chfast commented Jan 24, 2025

you can also repeat the imm_from_next_section case with a byte in the data section - even better if it's the data section of the parent container, not unlike the bug which Danno's fuzzing found recently.

But maybe that would be too much

This test is quite sophisticated: if you overflow reading of one section to the next one the validation will pass. This only works for the CALLF + "00" case. Therefore, I'm going to pass on parametrizing it.

@chfast chfast merged commit be1d1c9 into ethereum:main Jan 24, 2025
11 checks passed
@chfast chfast deleted the callf_truncated branch January 24, 2025 11:53
fselmo pushed a commit to fselmo/execution-spec-tests that referenced this pull request Jan 24, 2025
codeofcarson pushed a commit to codeofcarson/execution-spec-tests that referenced this pull request Jan 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants