security: disclose and detect host memory injection overlap - #4
Conversation
REPORT — Full merge sequence (all phases),
|
| PR | Merge commit | First parent | Second parent / merged head |
|---|---|---|---|
| #2 | de224446b392a426a3e88802ab238d2c12692d0d |
becb6fa1e0ca6d0a8238c566de1383aac6afc74b |
4855a15b201e2172b6c4534ea3b72c8f04c68a97 |
| #3 | a206aaa7ea069110a29fb0e441f5626e7c1c9ebc |
de224446b392a426a3e88802ab238d2c12692d0d |
ae61e7eca717bc50b9f6da1ac644ee09adaa72d3 |
| #4 | a9a99438c310f3d1b880e5318cabdb24e9b4fcff |
a206aaa7ea069110a29fb0e441f5626e7c1c9ebc |
fccea364625f9b20d6b2da475b4521961f1b3fb5 |
PR #3 recomputed to exactly the 12 authorized round-2 commits before fixes. PR #4 recomputed to exactly the three authorized round-3 commits (c2dd1eb, 13462e2, e4423da) before its test-only successor. Both merge trees were conflict-free; no rebase, force-push, squash, or history rewrite occurred.
Matrix evidence
Each run used the 12 named tuples: Ubuntu/macOS/Windows × Node 22.19.0/24.x × OpenClaw 2026.6.8/2026.6.9.
PR #3 first runs and finals
- Run
30746220794, head310af48: Ubuntu 4/4 success; macOS 0/4; Windows 0/4. macOS/Windows were non-blocking on this first run. All eight failures were the same false workspace-escape finding caused by canonical path spelling for missing default roots. - Run
30746321594, head112f5be: Ubuntu 4/4 and macOS 4/4 success; Windows 3/4 success. Windows Node22.19.0+ OpenClaw2026.6.9failed withEPERMduring concurrent graph-sidecar replacement. - Run
30746434982, head413d9ea: all 12/12 success, including Windows 4/4. - Blocking final run
30746542275, headae61e7e: all 12/12 success after removing non-blocking semantics. - Post-merge master run
30746645489, mergea206aaa: all 12/12 success.
PR #4 and final master
- PR run
30746766559, headfccea36: all 12/12 success, including the round-3 guard and per-agent override test on macOS/Windows. - Post-merge master run
30746863178, mergea9a9943: all 12/12 success.
GitHub Actions may display the first two PR #3 workflow conclusions as success because macOS/Windows were still continue-on-error; the per-job outcomes above preserve the actual lane results verbatim.
Fix and closure commits
| Commit | Purpose | Evidence |
|---|---|---|
310af48e9a40547185c2b88f78048d20c01e0d79 |
Moved pull_request from invalid permissions placement into the workflow trigger so the hosted matrix could run. |
All subsequent PR matrices instantiated 12 tuples. |
112f5be71e42ce6efc6d430f7b0df2fa0970a7c3 |
Canonicalized missing default roots relative to the real workspace path across macOS/Windows. | macOS 4/4 green on the next run; named symlink/canonicalization test added. |
413d9ea7d03223989df99139b353904453158439 |
Serialized concurrent atomic writes per sidecar path, preserving Windows backup/restore behavior. | Windows 4/4 green on the next and every final run; concurrent-replacement test added. |
ae61e7eca717bc50b9f6da1ac644ee09adaa72d3 |
Removed the macOS/Windows non-blocking guard. | Blocking final PR #3 matrix 12/12 green. |
fccea364625f9b20d6b2da475b4521961f1b3fb5 |
Test-only closure of the delegated per-agent override review item. | Test name: warns and reports health when a per-agent override re-enables host injection; asserts both warning and health finding; full matrix 12/12 green. |
Branch protection
master branch protection is active. strict is false so the audited stacked heads did not require an extra base-merge commit. All 12 exact matrix contexts are required:
build-validate-test (ubuntu-latest, 22.19.0, 2026.6.8)build-validate-test (ubuntu-latest, 22.19.0, 2026.6.9)build-validate-test (ubuntu-latest, 24.x, 2026.6.8)build-validate-test (ubuntu-latest, 24.x, 2026.6.9)build-validate-test (macos-latest, 22.19.0, 2026.6.8)build-validate-test (macos-latest, 22.19.0, 2026.6.9)build-validate-test (macos-latest, 24.x, 2026.6.8)build-validate-test (macos-latest, 24.x, 2026.6.9)build-validate-test (windows-latest, 22.19.0, 2026.6.8)build-validate-test (windows-latest, 22.19.0, 2026.6.9)build-validate-test (windows-latest, 24.x, 2026.6.8)build-validate-test (windows-latest, 24.x, 2026.6.9)
Release-boundary verification
- Remote tag baseline and final state both end at existing
v2026.6.18; no tag was created or pushed by this sequence. Final complete tag-list SHA-256:f07586ea731925638022956eff34afc667620fa90396e5a34f7480e1969aa684. - npm still serves
@ngo-a/native-memory-citations@2026.6.18, the same version recorded before Phase 1; nothing was published. CHANGELOG.mdon finalmasterkeeps all merged work under## [Unreleased]; no new version was stamped.- No ClawHub action, npm publish, deprecation, GHSA action, upstream filing, Notion edit, reporter attribution, or runtime dependency change was performed.
Hard stop / owner-only remainder
The merge sequence is complete and stopped. Remaining owner-only work is unchanged: any later release decision and release steps; the five staged 2026.6.17 steps in their standing order; filing both upstream issues; and the Notion threat-model mapping.
Verification report — native-memory-citations host-overlap round 3
Date: 2026-08-01
Executor: Ninja
Base:
6c7409b5132a9a5f4c7301bf81ddc28e361e200dVerified head:
e4423dae3ce7e3f769fba99dd1e2505be8e49d13Branch:
security/nmc-host-overlap-r3Status: PASS — ready for draft PR review
Stacking note: Retarget after PR #3 merges; PR #3 retargets after PR #2.
Changelog draft under
Unreleased:Scope and base controls
git ls-remoteand the fresh clone both resolvedsecurity/nmc-hardening-r2to the required immutable base6c7409b5132a9a5f4c7301bf81ddc28e361e200dbefore branching.rebased, force-pushed, retargeted, or otherwise mutated.
runtime dependency, merge, or reporter attribution occurred.
Commit sequence
c2dd1eb—docs: disclose host memory injection overlap13462e2—fix: warn on host memory injection overlape4423da—docs: draft host injection upstream follow-upThe upstream issue text is a release-owner draft artifact outside the plugin repo at
artifacts/handoffs/upstream-host-injection-redaction-issue-draft.md; C3 containsthe matching
Unreleasedchangelog entry. It was not filed.Empirical host configuration key
Discovered key:
agents.defaults.contextInjection.Evidence:
/tmp/nmc-gateway-e2e-20260801-tE7jqe/config-bounded.jsonandconfig-enhanced.jsoncontain noagents.defaults.contextInjectionoverride.openclaw@2026.6.9dev-dependency declaresAgentContextInjection = "always" | "continuation-skip" | "never"andAgentDefaultsConfig.contextInjectioninnode_modules/openclaw/dist/types.openclaw-*.d.ts.docs/gateway/config-agents.mdstates thatalwaysis the default.agents.list[].contextInjectionoverrides are also typed. The guardtreats an explicit default
neverplus no re-enabling override as disabled.The stop condition did not apply. Unknown or malformed versioned shapes return an
unknown state and fail open with a warning; they are never interpreted as disabled.
Guard scenario matrix
always)never+ no re-enabling per-agent overridecron_changed; no throwFocused test command:
Result:
26/26passed.The built plugin was also loaded with an isolated OpenClaw
2026.7.1-2doctorprofile. Doctor emitted:
Direct SDK registry verification with
getHealthCheck()confirmed thatnative-memory-citations/host-injection-overlapis registered and returns a warningfinding with
ocPath: agents.defaults.contextInjection.Observed-adjacent host behavior: OpenClaw
doctor --lint --onlyenumerates its checkIDs before the external plugin is loaded, so plugin-contributed health IDs are not
selectable in that CLI path on tested OpenClaw
2026.6.9or2026.7.1-2. Theregistration-time warning is nevertheless visible during doctor/plugin loading and
the health finding exists in the shared SDK registry. No plugin change was added
outside this handoff to alter host doctor enumeration.
Full verification battery
Environment:
7.0.0-28-generic, x86_64v24.18.111.16.02026.6.92026.7.1-2npm cinpm run test:typechecknpm testnpm run test:stressnpm run test:coveragenpm run plugin:build:checkgit diff --check 6c7409b..HEADnpm cireported the existing dependency audit state (12 findings) without changingthe lockfile. Round 3 adds no dependency.
Plugin-side E12 redaction recheck
Command:
Result: PASS. A secret-bearing
MEMORY.mdfixture produced a snapshot and injectedcontext containing the redaction marker and zero occurrences of the raw controlled
value. This rechecks the plugin side of E12 only; host-native raw injection remains
outside plugin control and is the condition disclosed and detected by this round.
Documentation no-daylight check
PASS.
OpenClaw's independent workspace-bootstrap path.
that host path, and that log retention is a secret-handling concern.
A reader of either document cannot reasonably conclude that installing the plugin
prevents raw host-native memory from reaching the model on a default OpenClaw host.
File-scope audit
Files changed relative to PR #3 head:
Every changed file is explicitly required by WO-R3-1, WO-R3-2, its tests, or the
ordered changelog draft. No other PR #2/#3 file was touched.
Draft artifact
G1 draft created at:
artifacts/handoffs/upstream-host-injection-redaction-issue-draft.mdIt requests a pre-injection redaction hook, alternatively per-workspace suppression,
trajectory diagnostic scrubbing/retention policy, and discoverable injection state.
It contains no workspace paths, fixture secrets, or reporter names. Mo owns filing.
Merge posture and owner ledger
This stacked round-3 PR must target
security/nmc-hardening-r2and remain draft.Retarget only after PR #3 merges; PR #3 itself retargets only after PR #2. Round 3
does not change PR #3's existing merge posture: Windows remains its only open
platform surface.
Mo-owned and not performed:
All explicitly out-of-scope adjacent items remain unimplemented.