Three mods run inside the user's Command Code session with the permissions the harness grants to a mod. Their trust boundaries are deliberately narrow.
- The only thing it executes is the project's own check. Fallback
verification runs the command the repository declares (
package.jsonscripts,Makefile,Cargo.toml,go.mod,pyproject.toml, adotnetproject) throughcmd.exec. That is arbitrary code from the repository you opened — the same trust you already extend to the agent. It is announced in the feed before it runs, bounded to five minutes, and only runs after the agent was asked to run it and didn't. - No network. The mod makes no outbound requests. Its one model call is
cmd.model.completeon the session's own model client, for the optional criterion and next-step suggestion. - No project writes except the episode receipt. It appends one redacted
JSON line per verified run to
.agents/learning/episodes.jsonl; it never edits or deletes files. - No prompt injection surface. It adds nothing to the system prompt, and every message it injects is built from local state (paths, counts, command labels, checklist text), never from tool output.
- Bounded authority. The veto can only block a shared-state shell command
(
git push, publish, deploy, cluster apply) and only when the current typed task did not ask for it. It never approves, rewrites input, or escalates permissions.
- It writes project files by design: drafts under
.agents/learning/and promoted skills under.agents/skills/. Nothing is written outside the project, and nothing is ever deleted (archive is a move). - Generated content is treated as untrusted. The drafting completion reads episode text, which can contain text addressed to the model. Mitigations: explicit "data, not instructions" framing, bidi/zero-width stripping, injection-phrase and secret validation, and a mechanical requirement that every command in a draft appears verbatim in the evidence.
- Three independent episodes are required before a skill can be loaded. A single poisoned run cannot install a skill.
- Ownership is enforced. A skill without
debrief's.managed.jsonmarker is never edited, archived, or overwritten; a name conflict is surfaced instead. - No prompt writes. It never touches the system prompt,
AGENTS.md, or the taste system. Preference-shaped lessons go tosuggestions.mdfor a human to act on.
- Telemetry is local and user-level. Daily files under
~/.commandcode/mods/.telemetry/, 30-day retention. Nothing is written into a project, and nothing is sent anywhere except the analysis completion on the session's own model client. - Records are allowlisted. Counts, timings, categories, hashed project keys, check labels, skill names, and veto terms only. No prompts, code, file contents, absolute paths, or secrets reach the stream. Error messages are redacted and truncated.
- The issue body is generated from an allowlist, not by copying raw data: versions, platform, metrics, and validated findings. Project keys only — no names, paths, check labels, skill names, or veto terms. It is written locally and copied to the clipboard; it is never filed automatically.
- No self-modification.
instrumentreads only its telemetry directory and never edits a mod's source. A telemetry write failure never throws into a run.
Open a security advisory
or email [email protected] with the subject [command-code-mods security].
Please do not open a public issue for a security report.
Security fixes target the latest tagged release and main. The pre-2.0 suite
in legacy/ is archived and receives no fixes.