Repository navigation
Bound decoded policy packages before allocation - #108
Merged
Merged
Conversation
Co-authored-by: GPT-6 <noreply@openai.com>
Co-authored-by: Codex GPT-6 <noreply@openai.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Policy ZIPs were inflated before their decoded size was accounted for. A small upload could therefore allocate arbitrary decoded data before the BASIC compiler or neural runtime applied its limits.
Enforce a shared 64 MiB budget across decoded source, resource contents, resource names, and accounting overhead. Pin the bounded Zippy decoder to
relh/zippy@d605465c98b9666f9a5232cece5a0441c10d159ein both dependency locks; upstream change: treeform/zippy#2. Each extraction receives the remaining budget and counts actual output, including false ZIP size metadata. This bounds retained package data, not total process memory.Extend the existing native Coworld runtime harness with aggregate-overflow and forged-size cases.
COWORLD_TEST_ARTIFACTSretains episode evidence for independent inspection.Validation: existing Zippy suite and Polyworld package-loader tests pass. The compiled GotA native Coworld workflow passes 21 episodes on Linux amd64, including both new rejection cases, inside a network-disabled container limited to two CPUs and 4 GiB. Game logs attribute the failures to player zero, publish its failed status, omit game results, and retain healthy contract endpoints. The workflow uses the real compiled game and staged player files; no browser workflow was exercised. These checks establish loader/runtime behavior, not learned strength or full VM isolation.
Regression control: removing decoder limits from the actual game source lets the aggregate oversized package complete gameplay instead of producing the required player failure. The same harness fails at its 120-second missing-failure deadline. The original source was restored byte for byte; all positive and negative-control evidence is retained.
Reproduction: compile
examples/gods_of_the_arena/gota.nimwith-d:coworldtotmp/coworld/gota, then runnim r coworld/tools/test_runtime.nim gotawith pinnedPOLYWORLD_DEPSand an existingCOWORLD_TEST_ARTIFACTSdirectory.[Codex, acting on behalf of Richard Higgins]