docs: qualify parity and document runner and preopen limits - #16
Merged
Merged
Conversation
The README promised byte-identical output unconditionally, but the environment (e.g. SHELLCHECK_OPTS) and visible files change results too; the glossary definition of Parity omitted the environment as well. State that the runner blocks with no timeout, cancellation or output limit, and that preopen containment is checked per call rather than enforced atomically, so the Host must not expose directories an untrusted process rewrites during a run. Show dispose() in a finally.
…nd-preopen-limits
|
🎉 This PR is included in version 0.2.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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.
Summary
Corrects the README's unconditional parity claim and documents the limits a Host needs to know about: the runner blocks with no timeout, cancellation or output limit, and read-only preopen containment can be raced by a concurrent writer.
Changes
README.md: parity now holds "given the same args, stdin, environment and visible files" (e.g.SHELLCHECK_OPTSchanges output). Usage example disposes the preopen infinally. New paragraphs on the runner's blocking behaviour and on the preopen race.CONTEXT.md: the Parity definition adds "environment", matching the README.src/host-preopen.ts:createReadOnlyPreopendocstring states that the containment check is not atomic with the open, and thatdispose()must run even if the run threw. Comment-only change.Issues
Closes #13, except its last item: a "documentation test" guarding the parity wording is not added; review covers it.
Refs #11. That issue asks for
openat-style traversal, which Node'sfsAPI does not offer, so the race cannot be closed in pure JS. The exploit also needs a process rewriting symlinks in the exposed directory while ShellCheck runs. This PR documents the limit so Hosts can decide; ADR 0005 already gives the Host ownership of isolation. I suggest closing #11 as won't-fix once this lands. Your call.