Enforce resolved material access boundaries - #291
Merged
Merged
Conversation
This was referenced Sep 9, 2026
nahiyankhan
force-pushed
the
fix/ghost-pass1-hardening
branch
from
September 9, 2026 04:34
6185b8b to
8ef17ce
Compare
nahiyankhan
marked this pull request as ready for review
September 11, 2026 05:06
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.
Category: fix
User Impact: Hosts can enforce material-read permissions even when a bundled path is a symlink.
Problem: A bundled symlink could resolve outside the materials directory while retaining bundled permissions and inline limits.
Solution: Classify local material after resolving its real path. Require referenced-file permission and apply the referenced inline limit when the target leaves the materials directory; keep outside-repository targets unavailable.
Compatibility: Internal symlinks remain supported. Pull still inlines eligible referenced text by default; permission-sensitive hosts should use
inlineMaterials: falsebefore inspection.Scope: Narrowed from the original 32-file PR to the material-access fix. The other four concerns have separate draft PRs; this branch targets
main.Related: Preserve guidance meaning in CLI output, Report incomplete guidance loading, Add read-only installed skill checks, Fix and validate rendered guidance examples.
Validation:
pnpm run quality:all: passed on this standalone branch, including build, package/release checks, tests (231 passed), workspace builds, and package validations.git diff origin/main...HEAD --check: passed.Changeset: Existing patch changeset retained.
ghost Review: Review packet assembled against
apps/docs/.ghost. This package does not bind the changed CLI/test/docs files, so the packet is coverage context, not a passing brand review. Used the currentghost review --package apps/docs/.ghost --base origin/main --format jsonand inspectedghost manifest; the olderghost check,--include-memory, anddump:cli-helpworkflows are unavailable in this checkout.File changes (6 files)
.changeset/material-realpath-policy.mdpackages/ghost/README.mdpackages/ghost/src/embed/inspect.tspackages/ghost/src/ghost-core/material-transport.tspackages/ghost/src/skill-bundle/references/schema.mdpackages/ghost/test/material-access.test.tsScreenshots/Demos: N/A: no visual surface changes.