{
  "schema": "cain42.sovereign.evo02.enforcement_map.v1",
  "generated": "2026-10-12",
  "host_kernel": "Linux 7.0.0-38-generic",
  "host_lsm": "lockdown,capability,landlock,yama,apparmor,ima,evm",
  "landlock_abi": 8,
  "rule": "telemetry is never counted as prevention; 'blocks_before_execution' is true only where a test shows the operation did not happen",
  "paths": [
    {
      "path": "MCPGate HTTP proxy (cain/mcp_proxy.py create_mcp_proxy_app)",
      "operation": "tool call",
      "mechanism": "application: process_incoming_request -> consume_jit_capability before httpx forward; mid-flight + pre-release containment re-check",
      "blocks_before_execution": true,
      "privileges": "none (user-space proxy)",
      "kernel_requirements": "none",
      "bypass_conditions": [
        "agent reaches the downstream tool server directly (network path not forced through the proxy)",
        "proxy process / host compromise"
      ],
      "evidence": [
        "tests/test_sovereign_e2_token_precedence_side_effects.py (side-effect counter 0 on every deny)",
        "tests/test_mcp_proxy_midflight_revocation.py"
      ],
      "status": "IMPLEMENTED_AND_TESTED (application level)"
    },
    {
      "path": "MCPGate stdio proxy (StdioMCPProxy.run)",
      "operation": "tool call",
      "mechanism": "application: same decision + JIT consumption before writing to the child's stdin",
      "blocks_before_execution": true,
      "privileges": "none",
      "kernel_requirements": "none",
      "bypass_conditions": [
        "agent spawns the tool server itself",
        "proxy process / host compromise"
      ],
      "evidence": [
        "tests/test_sovereign_e2_token_precedence_side_effects.py::test_stdio_* (real child process, counter 0 on deny)"
      ],
      "status": "IMPLEMENTED_AND_TESTED (application level)"
    },
    {
      "path": "stdio tool server process (child of StdioMCPProxy)",
      "operation": "setuid/setgid family, capset, ptrace, process_vm_*, module load, kexec, reboot, syslog, bpf, chroot",
      "mechanism": "kernel: PR_SET_NO_NEW_PRIVS + seccomp filter (default ALLOW, EPERM list); proxy refuses to start the child if the filter cannot be built unless CAIN_STDIO_ALLOW_UNSANDBOXED=1",
      "blocks_before_execution": true,
      "privileges": "none (unprivileged seccomp)",
      "kernel_requirements": "Linux seccomp + libseccomp.so.2",
      "bypass_conditions": [
        "operator sets CAIN_STDIO_ALLOW_UNSANDBOXED=1",
        "syscalls outside the EPERM list"
      ],
      "evidence": [
        "tests/test_sovereign_e2_stdio_seccomp_reality.py (measured EPERM)"
      ],
      "status": "IMPLEMENTED_AND_TESTED"
    },
    {
      "path": "stdio tool server process",
      "operation": "subprocess exec, file read/write/unlink, outbound TCP",
      "mechanism": "NONE at the kernel: allowed by the seccomp filter (measured). Governed only by MCPGate's per-call decision and by what the tool server chooses to do",
      "blocks_before_execution": false,
      "privileges": "n/a",
      "kernel_requirements": "n/a",
      "bypass_conditions": [
        "a malicious or compromised tool server can exec, write files and open connections without any CAIN decision"
      ],
      "evidence": [
        "tests/test_sovereign_e2_stdio_seccomp_reality.py (measured OK)",
        "formal/z3_results.json tool_server_performs_unauthorized_exec_file_or_network_op = SAT"
      ],
      "status": "NOT_IMPLEMENTED (kernel enforcement); candidate: Landlock ABI 8 is available on this host (Evolution 3)"
    },
    {
      "path": "Hosted /mcp tools on the gateway (cain/continuum/hosted_pipeline.py middleware)",
      "operation": "tool call",
      "mechanism": "application: restriction-only pipeline v27 + carve-out guard stack before the tool body (in-process)",
      "blocks_before_execution": true,
      "privileges": "none",
      "kernel_requirements": "none",
      "bypass_conditions": [
        "caller identity is self-asserted (_cain_agent/_cain_tenant arguments) for stages that bind agent/tenant",
        "gateway process compromise"
      ],
      "evidence": [
        "tests/test_sovereign_e1_hosted_proof_stage_fail_closed.py",
        "Evolution 1 live config inspection"
      ],
      "status": "IMPLEMENTED_AND_TESTED (application level)"
    },
    {
      "path": "Hosted gateway process",
      "operation": "exec / file / network by hosted tool bodies",
      "mechanism": "NONE at the kernel: tool bodies run in the gateway process; cain-ebpf/cain_enforce.bpf.c is a tracepoint program that always returns 0 (telemetry, per session -17); BPF LSM is not in the active LSM list",
      "blocks_before_execution": false,
      "privileges": "n/a",
      "kernel_requirements": "BPF LSM or Landlock would be required",
      "bypass_conditions": [
        "any code path inside the gateway process"
      ],
      "evidence": [
        "reports/sovereign/evolution-01/s17/findings.json T-S17-05, D-S17-06"
      ],
      "status": "NOT_IMPLEMENTED -> production release BLOCKER (T-S17-05)"
    },
    {
      "path": "SDK guard (cain.guard / cain_sdk.guard, in-process)",
      "operation": "guarded function call",
      "mechanism": "application: local allowlist or remote gateway decision; offline fallback now fails closed (9672bdc1)",
      "blocks_before_execution": true,
      "privileges": "none",
      "kernel_requirements": "none",
      "bypass_conditions": [
        "T-S17-04: an unsigned ALLOW from whatever answers at the gateway URL is accepted and cached",
        "the host application simply calls the function without the guard"
      ],
      "evidence": [
        "s17/findings.json T-S17-03 (fixed), T-S17-04 (open)"
      ],
      "status": "IMPLEMENTED_BUT_NOT_FULLY_TESTED; T-S17-04 OPEN"
    },
    {
      "path": "Gateway sandbox / exec routes (/sandbox/execute, /frontier/kernel/sandbox-run, /fabric/openshell/execute-sandboxed, /fabric/contracts/invoke-exec, /fabric/continuum/verify/run)",
      "operation": "code / command execution",
      "mechanism": "authentication gates (tenant key, operator credential, disabled-by-default); no MCPGate decision; OpenShell engine vets argv",
      "blocks_before_execution": true,
      "privileges": "operator or tenant credential",
      "kernel_requirements": "per route",
      "bypass_conditions": [
        "credential theft",
        "route-specific policy gaps not re-tested in Evolution 2"
      ],
      "evidence": [
        "s17/findings.json alternative_routes_checked"
      ],
      "status": "IMPLEMENTED (authentication), not re-tested here"
    }
  ]
}