Skip to content

fix(codex): classify effective storage configuration layers before native dispatch #166

Closed

Description

@abruption

Verified gap

At TS main 90481b148584926ea328ed956327f3050d9be9cb, sqliteHome() checks only the root sqlite_home key in /config.toml. Send uses that result and removes CODEX_SQLITE_HOME from the child environment, but does not classify system, managed-preference or project configuration layers before the native queue command. The validation contract assumes the selected home contains the SQLite state being used.

Python main f5e7c49554ff02771990a151e00b52f2abf3df0a now explicitly classifies system/requirements paths, project configuration, and storage/child environment checks. Its native-version-dependent macOS preference handling and queue/consumer cwd checks also need evaluation, not blind copying.

Expected behavior / impact

Unsupported relocation or unclassifiable effective storage must be refused before native submission; selected-home validation alone must not be represented as effective-storage verification. A non-default configuration layer can make the checked location differ from the native loader's location. This is a source-established coverage gap, not a newly reproduced wrong-database delivery or security exploit.

Acceptance criteria

  • Pin supported native Codex loader versions and document which system, requirements, managed-preference and project/cwd layers apply on each platform; fail closed where classification is not supported.
  • Share bounded, sanitized storage classification between doctor and dispatch. Preserve existing environment stripping, TOML semantic parsing and malformed-input refusal from fix(codex): keep the validated SQLite home and the codex queue database in sync (CODEX_SQLITE_HOME / sqlite_home) #50/fix(codex): detect escaped TOML sqlite_home keys before queueing #94/fix(deps): reject malformed exponent signs in Codex configuration #163.
  • Inspect the actual queue process cwd and relevant consumer/project context; do not silently switch databases, remove preferences or rewrite user configuration.
  • Revalidate the applicable storage evidence immediately before effect, including ordinary and app-server/handoff submission paths, while retaining writer identity and unknown/no-resend semantics.
  • Add isolated fixtures for each supported layer, absent/malformed/unreadable configuration, escaped keys, conflicting locations, version-sensitive macOS preferences and changes between validation and dispatch. Refusal tests must assert zero native submission calls.
  • Record native-loader verification separately from fake-child tests and document unqualified platforms.

Scope and verification limits

Follow-up to completed #50 and #94, not a claim that their environment/key-parser fixes are absent. Full issue/PR inventory checked; no issue specifically tracks these additional layers. This review ran no native Codex command, queue test or TS test suite. The Python report's 964-test result is not TS evidence. No credentials, real sessions, live writes, configuration changes or new relocation support are requested.

Activity

  1. abruption commented on Oct 29, 2026

    @abruption
    OwnerAuthor

    Milestone triage — 2026-10-29: assigned to 0.5.2 as the first correctness/safety priority for existing dispatch. Require supported native-loader/version/platform evidence and refusal before ordinary and app-server/handoff effects when effective storage cannot be classified. This is a source-established coverage gap, not a newly reproduced exploit or permission to add relocated-storage support. #167/#168 maintenance must not delay a necessary guard correction; #165 is independent.

  2. self-assigned this
    on Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions