Scripts: reject trailing BCPack table bytes under optimization #2733
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!2733
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/2733/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@luckyteagirl on GitHub · 2026-11-26 09:10 UTC · original
luckyteagirl:codex/bcpack-trailing-bytes→main· +53 −1 · 2 files · 1 commits · closed without mergingPython's optimized mode strips the assertion that checks whether the BCPack table parser consumed all input. A VIctory table with extra bytes can then overwrite the generated Rust file as if it were valid.
What is in it
Tested
b49be183, 1 passed and 1 failed. The optimized malformed input unexpectedly exited 0.git diff --checkpassed.Regression run
Script and test changes only.
Not tested
AI use
OpenAI Codex (GPT-6) reproduced the issue, wrote the patch and tests, and ran the checks above.
@luckyteagirl on GitHub · 2026-11-26 09:15 UTC · original
Closing this draft in favor of #1440. Independent review found that #1440 already replaces the trailing-data assertion with explicit validation, checks the exact input size before output, and adds tests in the same script test file. Our optimized-Python case is covered by that explicit validation and does not warrant a competing PR. Thanks to the #1440 author for the broader fix. AI-assisted duplicate check (OpenAI Codex, GPT-6).
Pull request closed