Skip to content

Restore opt-in Codex app-server state safely after Box restart #134

Description

@BrettKinny

This was generated by AI during triage.

Type: HITL

Parent

What to build

Design and implement an opt-in way to restore a previously enabled Codex
app-server daemon after Box replacement or restart without allowing
user-controlled Managed-home paths to be traversed or deleted as root. Treat
the upstream app-server state layout and experimental command contract as
untrusted, versioned integration inputs rather than a stable Squarebox
interface.

Acceptance criteria

  • Record the supported Codex command/state contract and the behavior when that upstream contract is absent or changes.
  • Opt-in state is explicit and does not infer authority solely from the presence of an upstream settings file.
  • Root entrypoint code never follows, removes, truncates, or changes ownership through a Managed-home symlink or unexpected file type.
  • Stale process metadata cleanup runs as the Managed-home owner against validated paths and preserves original diagnostics on failure.
  • HOME, UID/GID, PATH, and ownership are correct in root-remap and already-unprivileged entrypoint paths without hard-coded host assumptions.
  • Missing Codex, malformed state, a running daemon, stale state, timeout, and daemon failure never wedge Box startup.
  • Deterministic automated tests cover opt-out, opt-in, symlink/file-type attacks, ownership, both entrypoint paths, timeout, and restart idempotence.
  • Documentation and SECURITY describe the process lifecycle, trust boundary, logs, and recovery command.
  • Live restart qualification confirms pairing and control-socket health on a supported installation.

Blocked by

None - design can start immediately. Implementation remains outside v1.2.0.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestready-for-humanRequires human implementation or judgment

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions