Repository navigation
Prevent task images from exposing future Git history - #1
Closed
reinainblood wants to merge 2 commits into
Closed
reinainblood wants to merge 2 commits into
reinainblood wants to merge 2 commits into
Conversation
reinainblood
marked this pull request as ready for review
August 20, 2026 19:35
Collaborator
|
Thanks so much for the careful report, the reproductions on krep and libyang, and the work on this PR! Sorry for the delayed response. We’ve since addressed the future-history exposure through a separate implementation in #2. The rebuilt images remove Git refs outside HEAD’s ancestry and prune unreachable objects, while preserving ancestor tags. As documented in our release notes, the reference patch passes all 170 tasks, and the empty patch fails all 170. Your caveat about lower image layers still applies: agents must not have Docker-socket or image-export access. We really appreciate you catching this and contributing a concrete fix. Thank you again! |
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.
What this fixes
Some released task images are checked out at
base_commitbut still exposelater, answer-bearing commits through normal Git history. That lets an agent
recover the reference change with
git log/git showinstead of solving thetask.
I confirmed this in two public images:
davidesantangelo__krep-c_1eb6a4aCESNET__libyang-c_8d3d805In both images the target commit is available after the declared base. On the
files touched by the dataset patch, the stable patch ID of
base..targetmatches the published golden patch.
Changes
base_commitand itsancestors while removing later and unreachable Git objects.
directories, and initialized submodules; recursively seal submodules to their
recorded gitlink commits.
build tools using
git describe --tagscontinue to work.history check, pull-failure handling, and selected image IDs in results.
rebuilt/squashed images at immutable digests.
Prediction rows cannot choose their Docker image. When an image map is
supplied, it must cover every evaluated prediction, so a run cannot silently
mix sealed and original images.
Validation
attached and detached HEAD, dirty/untracked worktrees, nested paths,
initialized submodules, total image-map coverage, local-only selection, and
result image receipts.
shellcheck,bash -n,py_compile, andgit diff --checkpass.target commit is absent and the sealed-history check passes.
including CESNET/libyang's nested
/testbed/buildworking directory.Scope
This PR supplies the preparation and evaluation controls, but it does not
rewrite already-published image tags. A derived Docker layer removes the old
Git database from the ordinary container view; it does not physically erase
bytes from lower image layers. Agents must remain unprivileged and must not
receive Docker-socket or layer-export access. For a release, the prepared
images should be rebuilt or squashed, published at immutable digests, and
checked across all 170 instances before updating the benchmark image map.