Secure Craik
Craik treats governance as a runtime concern. Policy envelopes, capability grants, credential identity, redaction, and sandboxes are all addressable objects — not advisory configuration. This section is the implementation map for everyone responsible for the safety, identity, and audit properties of their Craik install.
Implementation paths
- 02Model
Governance model
The top-level statement of intent: Craik must be governance-native, not an enterprise add-on. Policy travels with every run, every grant is typed, every immutable boundary is enforced.
Read - 03Grants
Capability grants
Side effects require explicit, scoped grants — no ambient authority. Three practical outcomes: allowed, denied, or requires_approval. The v0.1 runtime enforces four capability hooks today.
Guide - 04Scope
Scope control
The six intent-lock knobs (
Guideaccepted_interpretation,in-scope,out-of-scope, allowed autonomy, stop conditions, scope-change rules) plus the mid-run update flow. - 05Exception
Fail-open behavior
Default is fail-closed. Fail-open is profile-gated, opt-in only, and never bypasses redaction, receipts, immutable paths, or memory-write approvals. Automation is always fail-closed.
Guide
Profiles · 01
Policy profiles
The named profiles Craik ships — strict (default),
trusted-local (opt-in fail-open), and automation
(strict-but-headless). Design rationale lives in
ADR 0004.
- strict default
- trusted-local
- automation
- ADR 0004
Design rationale
Design rationale: ADR 0004 Policy Envelope Shape — actor, task, profile, grant requirements, redaction posture, and receipt obligations all bound into one typed record.
— Policy profiles · §Intro
- 02Gate
Policy tests
Referencecraik policy testis the machine-readable policy regression gate for v0.1. Exits non-zero on any violated check and prints a structuredcraik.policy_test_report. - 03Operator
Running policy tests
How operators and release engineers run the policy gate locally and in CI — what each of the six checks covers, how to extend the suite, and where the harness touches local state.
Guide
- 02Guard
Redaction
The central runtime redaction utility runs before every persistence boundary. Bearer tokens, key/value secret shapes, auth URLs, configured patterns, and structured fields with secret-like names — all scrubbed before storage.
Reference - 03Policy
Secret migration policy
Migrations must never copy secret values across runtime boundaries. Four policy outcomes:
Referenceredact·strip·reference·reject— never copy as-is. - 04Process
Security release process
Security releases use the same package gates as normal releases, plus additional advisory and disclosure handling — so security fixes never skip the regression suite or the doc-update obligation.
Process
- 02Inbox
Contradiction inbox
First-class workflow record for "two things disagree" — docs vs. implementation, handoff vs. branch state, reviewer vs. implementer. Distinct from Stigmem memory-substrate conflicts; cross-linkable when both exist.
Guide - 03Lifecycle
Memory proposals
Create, list, approve, reject — and the promotion rule that requires evidence. Direct durable writes still need a
Guidememory.writegrant; until then, proposals are the path. - 04Audit
Memory diffs
What a task changed in memory: proposals created, approved, rejected; facts written and read; write failures. The single object reviewers inspect when deciding whether a run's memory effect was acceptable.
Guide - 05Preview
Memory impact preview
The read-only forecast before promotion: facts that would be added or invalidated, likely contradictions, proposals missing evidence, and scope visibility counts. Previews never write.
Guide
- 02Backend · local
Local process backend
Execution through the host process environment. Intentionally a decision boundary — not ambient shell. Local backend doesn't grant runtime authority unless a matching grant exists.
Reference - 03Backend · remote
Remote shell backend
SSH or equivalent remote command execution as an auditable boundary. The backend records the decision; it does not open connections or execute commands by itself.
Reference - 04Backend · docker
Docker sandbox backend
Containerized execution as an explicit environment boundary. The backend records image, build args, and grant boundaries — it doesn't start containers itself.
Reference - 05Backend · browser
Browser tool boundary
Browser automation and tool execution as a policy-controlled sandbox. The boundary captures origin, profile, allowed surfaces, and the receipts emitted for each navigation or action.
Reference - 06Receipt
Environment receipts
Normal
Referencecraik.capability_receiptrecords for provider, MCP, sandbox, local process, remote shell, browser, and container decisions. One receipt shape across every environment surface.