← Model losses

Head-to-head comparison

openai / gpt-6-luna / low / low effort preferred over claude-code-cli / claude-sonnet-5-5 / medium / medium effort · close win.

Primary judge: Sol 6.1, requested Low. Effective provider effort and internal attempts were not verified. A close win is still a scored preference; it does not establish a material defect.

Reviewed public evidence

Task goal

Review the supplied native and Python private-capture implementations and owner/direct invocation contracts for confidentiality and evidence integrity. Trace the concrete input/output surfaces, credential-field exclusions, file permissions, immutable naming, failure retention, request binding, and reconnect/reconciliation behavior. Examine plausible credential leakage, path or symlink substitution, oversized/truncated envelopes and stale owner-process capture configuration against the actual code. Report only actionable findings with severity, exact packet file/line evidence, realistic trigger and smallest remediation. Separately list acceptance gaps that are not demonstrated defects. Do not inspect credentials/profiles, invoke tools, change files, run tests, or publish private contents.

openai / gpt-6-luna / low / low effort answer

## Actionable findings

**Medium — Credential-shaped strings in free text are not redacted.**  
The native and Python filters redact selected structured field names, but leave string values untouched (`security.packet.md:8–15`, `86–100`). The Python capture stores task input, native receipt, transport failure, and—when within limit—the sanitized raw envelope (`:184–198`, `:200–211`). A credential included in a question, output, error, or another unrecognized field can therefore be retained in the private capture. The code describes free text as private evidence, so this is a confidentiality risk if callers can supply secrets there. **Smallest remediation:** warn callers not to include credentials and/or add a narrowly scoped detector/redaction policy for credential-shaped free-text values before persistence.

**Medium — Python capture directory has a symlink/TOCTOU substitution window.**  
`_store` checks `directory.is_symlink()` before resolving, then performs later path-based operations (`:107–117`). An attacker able to modify the directory’s parent between that check and use could substitute the resolved path or a component; the final `O_NOFOLLOW` checks protect only the final opened component, not the full path (`:123–147`). **Trigger:** concurrent filesystem access by an actor with write permission to a path component. **Smallest remediation:** anchor operations to a trusted directory file descriptor and use descriptor-relative, no-follow operations; ensure parent components are trusted.

**Low — Oversized raw envelopes lose their content digest.**  
For raw envelopes over 2 MB, the capture records a digest of the entire serialized envelope but sets `rawEnvelope` to `None` and labels coverage `digest-only-over-limit` (`:200–210`). This avoids storing an oversized payload, but does not bound serialization work or memory before the size check, and the digest alone cannot recover or inspect the omitted evidence. **Smallest remediation:** enforce a bounded serialization/input size before materializing the complete canonical JSON, and explicitly treat over-limit envelopes as incomplete evidence requiring reconciliation. The existing response path does mark response captures for reconciliation (`:212–217`).

## Not demonstrated defects / acceptance gaps

- **Credential-field coverage is not complete by proof.** The explicit key list omits plausible aliases such as `secret`, `bearer`, and provider-specific names (`:8–14`, `:86–100`). Whether those occur in these receipts is not shown; do not treat their presence as established.
- **Native capture’s size and failure behavior are unclear.** It bounds serialized terminal evidence at 8 MB and attempts identity-only failure retention, but storage permissions, atomicity, and enforcement are delegated to the native storage authority (`:24–43`). No defect is established from this packet.
- **Owner-process integration is unverified.** The packet explicitly says the already-running original Codex MCP process has stale environment/schema and automatic Python capture there is unverified (`:235`, `:484`). This is a capture-completeness gap, not evidence of credential leakage.
- **Request binding and reconnect behavior have positive evidence.** Requests are bound by `inputHash`; reuse with a different payload is rejected (`:308–310`). Uncertain submissions are not automatically retried; inspect/reconciliation uses durable receipts, ownership/session checks, and exact run matching (`:275–304`, `:305–306`). Reconnect subscribes before reconciliation and provides explicit advance recovery without relaunch (`:387–429`). No replay defect is demonstrated.
- **Immutable naming and failure retention are evidenced, with limits.** Python snapshots use content-hash filenames, exclusive hard-link creation, restrictive file modes, and readback verification (`:121–151`); native snapshots include the digest in the key and verify readback (`:27–35`). Python capture failures retain identity-only metadata when fallback storage succeeds (`:218–232`); native failure evidence is best-effort (`:36–43`). Fallback availability and native storage guarantees are not independently demonstrated.
- **Transport surfaces are limited but include private data.** The bridge sends authenticated loopback RPC and captures pre-request input, response envelope, and decoded output (`:443–467`). The packet asserts no auth/provider changes (`:235`), but does not show the transport implementation or prove the security properties of the authenticated loopback client.

**Next useful action:** validate the free-text credential policy and harden path operations; separately verify capture behavior in a fresh owner process and establish the native storage authority’s permission/atomicity guarantees.

claude-code-cli / claude-sonnet-5-5 / medium / medium effort answer

# Evidence packet: private-capture confidentiality and integrity review

Direct analysis of `security.packet.md` only. No team lanes, tools or file writes. Line numbers are packet lines. `validateInput`, `OpenCodeClient`, the storage backend and the Mission Control MCP schema are not in the packet and are treated as uncertain.

## 1. Actionable findings

**F1 – Medium: credential exclusion is an exact-match key denylist.**
- Evidence: native 3-4, 8-9; Python 18-20, 26-29. Keys are normalized, then matched exactly against a fixed set.
- The match misses `x-api-key` (→ `xapikey`), `authToken`, `idToken`, `sessionToken`, `secret`, `privateKey`, `accessKey`, `bearer`, and env-style names such as `OPENAI_API_KEY`.
- `token` is withheld only when its value is a string. Free-text values are never scanned, which the code acknowledges at Python 24.
- Trigger: a receipt, input or tool result carries `{"env":{"OPENAI_API_KEY":"…"}}` or `{"authToken":"…"}`. It is written to disk, and Python labels the envelope `exact`/`structured-credentials-withheld` (139-141), which gives false assurance.
- Fix: match on a normalized substring or regex (`secret|token|password|passwd|apikey|authorization|cookie|credential|privatekey|bearer|accesskey`). Explicitly allow counters such as `tokens`, `inputTokens` and `maxTokens`. Share one list between native and Python and test them with the same fixtures.

**F2 – Medium: native receipt stores raw input as `privateTaskContext`, unsanitized.**
- Evidence: native RPC 302 stores `privateTaskContext: input`, and `transition` persists it (240-241). `inspect` returns the receipt (346). Only the terminal snapshot (native 15) and Python (116) apply `privateEvidence`.
- Trigger: `privateCapture` is on and the submit input carries credential-like fields. They sit in the general request-key storage outside the 0700/0600 capture domain, and the sanitizer guards only the later snapshot copy.
- Whether `validateInput` rejects such fields is outside the packet.
- Fix: store `privateEvidence(input)` or only `inputHash`. The raw input is not needed for reconciliation.

**F3 – Medium: post-admission capture can throw and mask the native result.**
- Evidence: Python 116-119 (`[REDACTED: private constant]`, `.get` on payload/output) and the `record` build with `evidence_index` (120-130) sit outside the `try` that starts at 131.
- Trigger: the final `capture_[REDACTED: private constant](method, payload, output)` at 222 runs after the native call has succeeded. Deeply nested output hits `RecursionError` in the unbounded `[REDACTED: private constant]` recursion (the depth guard exists only in `evidence_index`). A non-dict payload raises `AttributeError` at 118. The exception propagates out of `_direct_rpc`, so the caller loses `runID` and state for an already-admitted submit and may replay it.
- The response-envelope capture at 215 may preserve the data, but the caller cannot see it.
- Fix: move lines 116-130 inside the `try`. Add a depth bound to `[REDACTED: private constant]`. Wrap the 222 and 218 calls so a capture failure returns `capture-failed` status and never replaces the native output.

**F4 – Low/Medium: no request/run binding check.**
- Evidence: Python 118-119 prefers `output.requestID` over `payload.requestID`. `_direct_rpc` (216-223) never compares the two. `nativeBattleID` can also come from caller-supplied `payload.runID`.
- Trigger: a stale, misrouted or replayed reply is filed under the reply's ID and returned as the answer to this request.
- Fix: if both IDs are present and differ, record both with `bindingMismatch: true`, set `reconciliationRequired`, and raise `BridgeError`.

**F5 – Low: retries are indistinguishable.**
- Evidence: Python records contain no time, attempt or sequence (120-130), and the filename is the content digest (53-54, 54).
- Trigger: two identical `submit-before` or `-response` captures from a replayed or uncertain submit collapse into one file. The retry count cannot be proven, which matters for the no-replay fence.
- The docstring says "each native battle ID groups snapshots", but the layout is flat digest names with no requestID or run prefix, so lookup requires scanning contents.
- Fix: add an attempt nonce and monotonic time to the record (the digest changes accordingly), or write a per-request sidecar index.

**F6 – Low: oversize and truncation behavior loses evidence.**
- Evidence: Python 51-52 raises when the record exceeds 8 MB, and the failure record is identity-only (152-155). The raw envelope is digest-only above 2 MB (139-140). The digest covers the sanitized form (135-137).
- The "exact" coverage label means exact parsed JSON, not wire bytes. A truncated or non-JSON body raises in `client.request` (209-212), leaving only the exception class name.
- Trigger: a large `needs-collection` or terminal output. The Python side keeps nothing. Native holds the receipt, but the F6 gap is that the bridge capture is then silently weaker.
- Native 27 behaves the same way: identity-only failure above 8 MB.
- Fix: spill oversized content to a separate digest-named file, or record the wire byte length and HTTP status at the client layer. Rename the label to `parsed-json-exact`.

**F7 – Low: directory and file hardening gaps.**
- Evidence: Python 41-49, 55-68, 157-159.
- Only the final path component is checked for symlinks. There is no `st_uid == geteuid()` check, and `mkdir(parents=True)` creates intermediate directories with umask defaults.
- A relative `OPENCODE2_[REDACTED: private constant]` resolves against the bridge's cwd.
- `os.link` fails on filesystems without hardlinks (exFAT/SMB under `/Volumes`), so every capture there becomes a failure. A pre-existing 0755 fallback directory makes the failure log fail with `logged=False`.
- Files are 0600, not read-only, so immutability is by naming and write-time readback only.
- Same-user path substitution is mostly mitigated: `O_NOFOLLOW` at 68 and 78, and a planted destination symlink makes `os.link` raise `FileExistsError`, which falls through to the NOFOLLOW open. The residual risk is a same-user adversary.
- Fix: require an absolute path, check the owner, and fall back to `O_CREAT|O_EXCL` when `link` is unsupported. Optionally set 0400 after the write.

**F8 – Low: reconnect/reconciliation load and ordering.**
- Evidence: native 406-408, 431-433, 242-243.
- Every `server.connected` and every execution event rescans all requests. For each terminal one it re-serializes, hashes and reads back up to 8 MB, outside `exclusively`.
- In `transition`, snapshot capture is awaited before waiters are woken and the event is emitted, so slow storage delays completion signals.
- Fix: skip requests already verified (an in-memory digest set), and run capture after `wake()`/`emit`.

## 2. Acceptance gaps (not demonstrated defects)

- **Stale owner process.**
  - Python reads the env on each call (113), so a stale owner MCP process silently returns `{'state':'disabled'}` inside `privateCapture`, with no hard failure.
  - The native `options.privateCapture` flag is independent of the Python env, so the two sides can disagree.
  - Original `team_moa` and direct Codex writer flows do not call the helper. No automatic capture completeness is claimed or shown.
- **Native admission states have no private snapshot.** Only `completed` and `terminal-incomplete` are captured (native 21). `admission-uncertain` and `admission-rejected`, the most reconciliation-critical states, are covered only by the mutable receipt plus Python's `-response` captures.
- **Native failure records are write-only.** `direct-private/v1/failure/*` records are never cleared or surfaced by `readTerminalCapture` (43-57). A later success leaves the stale `reconciliationRequired` record in place.
- **No tamper evidence beyond the same trust domain.** The native snapshot and the receipt share one storage. The digest is anchored externally only if the Python capture of an `inspect` response includes `privateTerminalCapture`.
- **`reconciliationRequired` is false for non-terminal `running` and `needs-collection`** on the final method capture (Python 146-148). This is only a labeling gap.
- **Unverified items.** `validateInput` field filtering, the `client.request` size and timeout behavior, and the storage `set` overwrite semantics are outside the packet.

## 3. Discarded hypotheses and likely false positives

- A symlinked final directory or destination is handled by the `is_symlink` check and `O_NOFOLLOW`.
- A leftover temp file is cleaned by the `finally` at 66-67. After a crash it is a 0600 file only.
- The native get-then-set race is benign because the key is content-addressed. A differing existing value triggers a readback failure and is not overwritten.
- Exception messages are intentionally not logged (151).
- `headers` is withheld at all nesting depths in both implementations.
- Returning the unsanitized native `output` to the caller is consistent with existing behavior and is not a new leak.

## 4. Next action

Fix F1-F3 first. They are small and local: a shared sanitizer test with credential-name fixtures, `try` scope and depth bounding in `capture()`, and sanitizing `privateTaskContext`. Then add the F4 binding check and the F5 attempt nonce. Verify the stale-owner and oversized-envelope gaps with targeted tests on the owner MCP restart path.

MATERIAL_EVIDENCE_CONFLICT: none. The only tension is the docstring claim at Python 110, "each native battle ID groups immutable snapshots", against the flat digest-only layout at Python 54, which is covered in F5.

Primary judge's stated reason

A receives a slight forced preference for a more evidence-bounded triage list and usable packet references, reducing unnecessary remediation based on unproved behavior. B's additional concrete exception-boundary finding is substantial counterevidence. This is a weak comparative preference, not an established material quality gap; an independent review could reasonably favor B's broader detection.

This reason is the judge's assessment. No independent factual-defect finding is asserted by this record.

Battle wave: 363476d6-e8c0-4ffc-9edf-97ef2eef4154. Pair: brp1_678243fb07489bbd45b81bc3cec3e4ada61f9b1d7e4854904c4e41a3b37a56d2. A separate independent review is required before calling a concern a verified factual defect. Judge disagreement is not recorded here.