Skip to content

Commit ef08452

Browse files
committed
refine: Claude Directory validation and security disclosures
1 parent 8b04b09 commit ef08452

7 files changed

Lines changed: 85 additions & 54 deletions

File tree

‎DIRECTORY-REVIEW-NOTES.md‎

Lines changed: 27 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,41 @@
1-
# Anthropic Claude Directory — reviewer notes
1+
# Claude Directory reviewer notes — LoopGrid Decision Evidence
22

3-
**Plugin:** LoopGrid Decision Evidence (`loopgrid`) · **Contact:** hello@loopgrid.io · **Privacy:** https://loopgrid.io/privacy/ · **Terms:** https://loopgrid.io/terms/
3+
**Plugin:** `loopgrid` · **Publisher:** LoopGrid · **Contact:** hello@loopgrid.io
4+
**Privacy:** https://loopgrid.io/privacy/ · **Terms:** https://loopgrid.io/terms/
45

5-
This repository does **not** claim to be approved or Anthropic Verified. The scanner must be run again after the new GitHub commit is pushed.
6+
This source is a Directory submission candidate, **not an Anthropic-approved or Verified plugin**. The latest captured portal scan evaluated `main @ 8b04b09` and reported four policy holds and four listing-field warnings. Run **Re-validate** again after this patch is pushed; do not assume that a scanner finding has cleared merely because its source was improved.
67

7-
## Declared execution surfaces
8+
## Actual executable surfaces and user consent
89

9-
- `.mcp.json`: one local `stdio` server, `uvx loopgrid-claude-launcher==0.1.0`. This **published** Claude-only launcher delegates to **unchanged** `loopgrid-mcp==0.1.0`. The direct pinned `uvx` shape is proposed to satisfy the scanner's prior `LAUNCHER_UNSUPPORTED` finding.
10-
- `hooks/hooks.json`: three native Python lifecycle hooks for PreToolUse, PostToolUse and PostToolUseFailure. Hooks are **off** unless both an operator sets `LOOPGRID_CLAUDE_MODE=observe|enforce` and a project has `.loopgrid/claude-code.enabled`. Enabled hooks run as separate declared local commands; they are not part of the MCP subprocess.
11-
- `scripts/doctor.py`: manual **offline** diagnostic; no network requests.
12-
- `tests/test_hook.py`: developer-only mock/loopback tests, not executed on install; no executable PNG references.
13-
- `.claude-plugin/icon.png`: asset file only; not an executable.
10+
- **MCP:** `.mcp.json` launches the published, pinned `uvx loopgrid-claude-launcher==0.1.0`, which depends on **unchanged** `loopgrid-mcp==0.1.0`. The server exposes six decision/evidence tools. It does not make a refund or execute an external business action.
11+
- **Hooks:** three declared Python commands handle `PreToolUse`, `PostToolUse`, and `PostToolUseFailure`. These commands execute **outside the MCP subprocess** and are visible in `hooks/hooks.json`. They exit without reading hook events, writing state, or contacting Core unless both `LOOPGRID_CLAUDE_MODE=observe|enforce` **and** the current project's `.loopgrid/claude-code.enabled` marker are set.
12+
- **Diagnostics/tests:** the offline diagnostic does not contact Core. Developer unit tests use mocked Core responses and loopback HTTP only. Security tests that check HTTPS policy use reserved non-operational example hostnames; they do not send requests to those hostnames.
13+
- **Icon:** the plugin's image is a static manifest asset. No command or interpreter executes or reads that image as program code.
1414

15-
## Network and credentials
15+
## Network boundaries and service key
1616

17-
MCP tools and enabled hooks contact the **operator-configured LoopGrid Core**; neither subsystem contacts a separate analytics provider. MCP tools can submit user-authorized decision/evidence payloads (including personal information if present) and Core may retain them beyond 30 days. Opted-in hooks send tool names, input/result SHA-256 commitments, hashed identifiers and numeric policy fields, not raw tool contents. Hooks keep local SQLite correlation records. Default bundle export excludes raw payloads.
17+
- Enabled hooks send tool names, input/result SHA-256 commitments, hashed identifiers and numeric policy fields to the **operator-configured LoopGrid Core**. The hooks do not send raw tool arguments or response bodies; a commitment of low-entropy text may still reveal information through guessing.
18+
- Invoked MCP tools can transmit additional user-approved decision/evidence records, possibly including personal information. The Core may retain those records longer than 30 days. Correlation state is also stored locally in SQLite. There is no separate analytics destination.
19+
- The only **intended** service-key source is Claude's `userConfig.service_key` with `sensitive: true` (`CLAUDE_PLUGIN_OPTION_SERVICE_KEY` for an explicitly configured session). The hook **does not read `LOOPGRID_SERVICE_KEY`** and extracts only named plugin/operational settings using `os.getenv`, never enumerating the full environment as its configuration. HTTPS is mandatory for remote Core; only loopback permits HTTP. Credential-bearing requests reject HTTP redirects.
20+
- The published launcher filters unrelated inherited application environment settings **after `uvx` starts**, but the package-manager process receives its parent's environment beforehand. This is an explicitly disclosed dependency-installation boundary, not proof that an API credential was exfiltrated.
1821

19-
Claude's sensitive `userConfig.service_key` option is the only intended source of the MCP and hook service key. The Claude-only launcher clears inherited arbitrary application environment values **after `uvx` starts**, but `uvx` itself receives the initial parent environment during dependency installation. That limitation cannot be eliminated by Python-level filtering alone; assess package-manager/network proxy controls and trusted registry access separately.
22+
## Captured scan findings and reviewer disposition
2023

21-
The repository's `uv.lock` is generated from published registry versions for review. **It is not an enforced runtime lock for direct `uvx`**. We do not claim otherwise. Confirm whether the Directory's Verified checker accepts this packaging shape.
24+
1. **`LAUNCHER_PACKAGE_REVIEW` (policy hold):** `uvx` pins the launcher distribution at `0.1.0`, but that invocation does not enforce the adjacent `uv.lock` for transitive runtime installation. `uv.lock` is a registry-resolved **audit snapshot**, **not** a launch-time lock. The upstream package is published separately. We request human review of the dependency chain; we do not claim the Verified-specific rule is automatically satisfied.
25+
2. **`UNREAD_ASSET_REFERENCED` (policy hold on the former reviewer notes):** the referenced image is static and never an executable. This document no longer spells its asset path. Please check the actual interpreter/command targets; none points to the image.
26+
3. **`MCP_FORWARDS_CREDENTIAL_ENV` (test finding):** the prior scanner matched a remote-address syntax in developer security tests with a credential-bearing mock environment. The HTTPS test now uses a reserved `.invalid` documentation hostname without making a network request; credential-bearing transport tests operate on loopback. These tests are not run at plugin install.
27+
4. **`MCP_FORWARDS_CREDENTIAL_ENV` (combined plugin finding):** named runtime settings are read locally, and an explicitly selected service key is sent only in the `X-LoopGrid-Key` header to the configured Core. The hooks do not enumerate all environment variables or send machine-wide service keys. Please review the declared hooks and Core transport together; these are legitimate product behaviors, not a claim of zero credential use.
2228

23-
## Prior scanner findings (commit f2cb2de, not a new scan)
29+
The Directory also reports the four fields `documentationUrl`, `privacyPolicyUrl`, `supportUrl`, and `termsOfServiceUrl` as unknown **to the Claude Code runtime** while confirming they are used for the Directory listing. These can remain. The static image and local-only MCP information notices are not policy holds by themselves.
2430

25-
1. Launcher package review / transitive dependencies: a pinned `uvx` launcher replaces unsupported `uv run`; generated `uv.lock` provides audit snapshot. **Outcome pending rescan**.
26-
2. Executable test referencing PNG asset: removed test-only asset reference. **Outcome pending rescan**.
27-
3. Credential + remote fixture combination: changed tests to isolated/local/documentation fixtures; legitimate plugin key access remains. **Outcome pending rescan**.
28-
4. Combined environment access + network diagnostic: `doctor.py` now offline; enabled hooks still intentionally contact configured Core. **Outcome pending rescan and possible human review**.
31+
## Reviewer demonstration (synthetic data only)
2932

30-
## Three reviewer demo prompts
33+
1. Record a *fictional* refund proposal in LoopGrid, without executing a refund, and note the returned decision ID.
34+
2. Explain `off`, `observe`, and `enforce` modes and the explicit project activation marker; do not activate anything without permission.
35+
3. Verify a sandbox decision and export its evidence ZIP, distinguishing Core-side verification from the separate offline verifier.
3136

32-
1. “Record a **synthetic** $15 refund proposal in LoopGrid, **without executing a refund**, and report the returned decision ID.”
33-
2. “Describe the LoopGrid guard modes and project-local opt-in marker. Do not activate a hook or modify permissions.”
34-
3. “Verify a test decision, then export its evidence ZIP. Distinguish service-side verification from independent offline verification.”
37+
Reviewer test access to a temporary Core sandbox can be arranged privately. Never commit service keys, real customer records or personally identifiable test data.
3538

36-
Reviewer test access to a temporary Core sandbox may need to be coordinated privately. Do not commit service keys or real customer records.
39+
## Compliance attestation — clarification needed before submission
3740

38-
## Compliance attestation caution
39-
40-
The Directory UI asks whether the plugin exfiltrates credentials or executes code outside declared MCP servers. This plugin has three **declared Python hook commands outside the MCP process**. Obtain confirmation from Anthropic on the intended interpretation before acknowledging a statement that might be literally inaccurate. Any credential exfiltration must be ruled out through actual review, not by checkbox selection.
41+
The Directory form states that the plugin does not exfiltrate credentials **or execute code outside declared MCP servers**. The plugin has three **separately declared Python lifecycle-hook commands**, and their execution is not inside the MCP subprocess. The form currently shows four acknowledgements checked. Seek Anthropic's interpretation or adjust the attestation before submitting if this makes the statement inaccurate; transparency is more important than removing a warning.

‎README.md‎

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -86,15 +86,15 @@ Prerequisites: Claude Code installed, Python 3.10+ available as `python`, `uv` (
8686

8787
3. In Claude Code, use `/mcp` to check that the `loopgrid` server is connected; use `/loopgrid:decision`, `/loopgrid:verify`, `/loopgrid:review`, or `/loopgrid:guard`. The MCP server's review tool is disabled by default. Installing the plugin does not grant review authority.
8888

89-
The plugin declares `core_url`, `workspace_id`, and a sensitive `service_key` using Claude plugin `userConfig`. It never **uses** an inherited machine-wide `LOOPGRID_SERVICE_KEY` for the hook or MCP launcher; the service key is sourced from Claude-managed plugin configuration. The MCP launcher forwards only a short allowlist of OS/runtime values to the downloaded package, deliberately omitting unrelated environment tokens, `PYTHONPATH`, and proxy credentials. This may require additional setup on machines that rely on a corporate HTTP(S) proxy. Remote Core URLs must use HTTPS; HTTP is permitted only for loopback Core. Local developer testing can set `CLAUDE_PLUGIN_OPTION_SERVICE_KEY` in the launching shell without storing it in the repository. On some Claude graphical clients, plugin `userConfig` prompts may require explicit configuration from the plugin manager or Claude Code terminal.
89+
The plugin declares `core_url`, `workspace_id`, and a sensitive `service_key` using Claude plugin `userConfig`. Its hook reads only a fixed allowlist of these and other explicitly named operational settings, rather than enumerating all process environment variables. It never **uses** an inherited machine-wide `LOOPGRID_SERVICE_KEY` for the hook or MCP launcher; the service key is sourced from Claude-managed plugin configuration. The MCP launcher forwards only a short allowlist of OS/runtime values to the downloaded package, deliberately omitting unrelated environment tokens, `PYTHONPATH`, and proxy credentials. This may require additional setup on machines that rely on a corporate HTTP(S) proxy. Remote Core URLs must use HTTPS; HTTP is permitted only for loopback Core. Local developer testing can set `CLAUDE_PLUGIN_OPTION_SERVICE_KEY` in the launching shell without storing it in the repository. On some Claude graphical clients, plugin `userConfig` prompts may require explicit configuration from the plugin manager or Claude Code terminal.
9090

9191
The plugin can also be distributed through a GitHub Claude Code marketplace. The main manifest is `.claude-plugin/plugin.json`; `.mcp.json`, `hooks/hooks.json`, and `skills/` are at the plugin root.
9292

93-
### Validated with real Claude Code on Windows
93+
### Validation status (October 11, 2026)
9494

95-
The **previous `uv run --locked` plugin** passed 50 Windows regression/security tests, native Claude Code hook capture, synthetic Core evidence recording and independent attested bundle verification. The **new pinned-`uvx` plugin candidate** passed 48/48 Windows Python tests, Python compilation, `uv lock --check` (38 resolved packages) and Claude Code strict manifest validation. The **published Claude-only launcher** independently exposed all six MCP tools through a Windows stdio client; its GitHub CI passed on Windows, Ubuntu and macOS. A clean Claude Code session using this *exact pinned-`uvx` plugin candidate* remains to be tested before the GitHub update. The previous real-world evidence tests must not be misrepresented as full end-to-end validation of the new launcher arrangement.
95+
The previous `uv run --locked` plugin passed 50 Windows regression/security tests and real Core/hook/evidence exercises. For the **published** `loopgrid-claude-launcher==0.1.0` integration, Windows MCP stdio discovery returned all six tools; a clean Claude Code `/mcp` session loaded exactly one LoopGrid server with six tools; `uv lock --check` and Claude's strict plugin validation passed. After a CI-environment diagnostic test correction, the current GitHub source at `8b04b09` passed **49 Python tests** on Ubuntu and Windows with Python 3.10 and 3.12. The new hook environment-selection regression test will be included in the next scan; run it on all CI platforms before submission.
9696

97-
The isolated five-event sandbox Core test passed with `evidence_complete` and valid signatures. It used a fresh workspace to keep validation separate from earlier test records. See [VALIDATION.md](VALIDATION.md) for detailed results. Tests do not establish that this plugin has been endorsed or reviewed by Anthropic.
97+
The prior five-event sandbox Core run passed with `evidence_complete` and valid signatures in an isolated workspace. The older default workspace had an unrelated existing integrity failure; we do not claim that it passed. A fresh end-to-end decision/execution/outcome test with this *exact* updated launcher and Core was not run, so those results must not be conflated. Details: [VALIDATION.md](VALIDATION.md).
9898

9999
### Decision → policy → authorized execution → outcome → verification
100100

@@ -161,23 +161,22 @@ This creates a **fresh isolated test workspace and sandbox policy**, records a s
161161

162162
## Current Directory status and Verified eligibility
163163

164-
The existing Claude Directory entry is a **draft**, not approved or Anthropic Verified. Its previous validation was against the older `uv run --locked` GitHub commit. This version uses a pinned **published** `uvx` Claude-only launcher, retains `loopgrid-mcp==0.1.0`, and includes privacy, documentation, support and terms URLs in `.claude-plugin/plugin.json`. The new scanner result is **unknown until Anthropic revalidates the updated GitHub commit**. No scanner finding or badge is claimed resolved in advance.
164+
The existing Claude Directory entry is a **draft**, not yet approved or Anthropic Verified. The latest captured source scan (`main @ 8b04b09`) **passed structural validation but reported 4 warnings and 4 policy holds**: pinned-`uvx` dependency review, a false-positive static-asset reference in reviewer documentation, and two credential/environment heuristic findings. The static-asset reference and test fixtures have been cleaned up; an explicit allowlist now restricts hook settings read from the process environment. **The findings are not considered cleared until Anthropic rescans the next commit.** The four listing-field `UNKNOWN_KEY` warnings are informational for fields consumed by the Directory.
165165

166-
`uvx` invokes the package manager **before** the launcher's Python environment filter can run, and `uvx` does not automatically enforce a project `uv.lock`. These are explicitly disclosed residual supply-chain/runtime limitations. The locked dependency snapshot is included for review and cross-checking. Three declared lifecycle hooks run as separate commands outside the MCP process; the Directory compliance statement regarding code execution outside declared MCP servers must be clarified with Anthropic before attestation. See [Directory reviewer notes](DIRECTORY-REVIEW-NOTES.md) and [release checklist](RELEASE-CHECKLIST.md).
166+
`uvx` starts the Python package manager before the launcher's environment filter runs and does **not** enforce this plugin's `uv.lock`. The lockfile is an audit snapshot, not a runtime security guarantee. Three declared lifecycle-hook Python commands run outside the MCP subprocess; the Directory compliance wording needs clarification before final attestation. See [Directory reviewer notes](DIRECTORY-REVIEW-NOTES.md) and [security boundaries](SECURITY.md).
167167

168168
## Validation and release
169169

170-
The **previous locked-launcher plugin** passed 50 Windows regression/security tests, real Claude Code decision/evidence workflows, live opt-in tool hooks, Core signed-chain verification, and attested standalone ZIP verification. The **separate published `uvx` launcher** passed 7 launcher security tests, Windows six-tool MCP discovery and Ubuntu/Windows/macOS GitHub CI. This candidate plugin's 48 unit tests passed in earlier Windows testing; a clean Claude Code install **using this exact updated plugin with the published launcher** must be smoke-tested before the single GitHub push. Do not confuse the previous full end-to-end tests with end-to-end results for the new launcher arrangement. See [VALIDATION.md](VALIDATION.md).
170+
The latest GitHub CI (`8b04b09`) passed **49 tests** on Ubuntu/Windows with Python 3.10/3.12. The preceding Claude-only launcher also passed seven launcher security tests, Windows six-tool MCP discovery and Ubuntu/Windows/macOS CI. The current patch adds a 50th regression test covering explicitly selected hook environment settings; re-run CI after applying it. The previous real Core lifecycle/evidence tests remain useful but were performed with the older local launcher.
171171

172172
```powershell
173173
python -m unittest discover -s tests -v
174174
python -m compileall -q scripts examples
175-
uv lock
176175
uv lock --check
177176
claude plugin validate --strict .
178177
```
179178

180-
This release source **includes the genuine 38-entry `uv.lock` generated on Windows** for `loopgrid-claude-launcher==0.1.0` and unchanged `loopgrid-mcp==0.1.0`. Run `uv lock --check` before the GitHub update. The lock is **not enforced** by the direct `uvx` runtime command; see [SECURITY.md](SECURITY.md).
179+
The repository includes the genuine 38-entry `uv.lock` generated against published `loopgrid-claude-launcher==0.1.0` and unchanged `loopgrid-mcp==0.1.0`. This file is **not enforced** by the direct `uvx` invocation. Do not submit or claim Verified until the latest portal findings and compliance declarations have been reviewed.
181180

182181
**Repository:** https://github.com/loopgridio/loopgrid-claude-code
183182
**LoopGrid:** https://loopgrid.io

0 commit comments

Comments
 (0)