Repository navigation
Description
What happened
Security and stability hardening audit finding TS-05 / Low (2026-09-28). Priority is an audit recommendation, not a claim of a production incident.
A Reply-To URI used as --to may carry codexHome, which becomes the explicit --codex-home. The TypeScript parser does not require it to be absolute. codexHome=rel/dir and codexHome=~/.codex are accepted and later resolved against the replier's working directory (or the remote login directory over SSH) instead of the sender's home.
The Python v1 reference rejects this: "Reply-To codexHome must be an absolute path" (POSIX or Windows absolute).
What you expected
codexHome in a Reply-To URI is accepted only as an absolute POSIX or Windows path; a leading ~ is refused, matching the Python contract.
Environment
- Baseline: published session-peer 0.2.0 (npm
latest), repository commit38a1300369443e064f58bb18e8bda70f31af0fbb. - Audit environment: macOS arm64, Node 22.14.0.
- No live message tests or production mutation.
- Reproduction: argument parsing with a synthetic HOME; nothing was sent.
Source evidence
- src/protocol.ts#L14-L17 — field validation only checks control characters
- src/protocol.ts#L25-L27 —
codexHomereturned ashomeunchanged - src/cli.ts#L56 — Reply-To route applied as the send target
Acceptance criteria
- Relative and
~-prefixedcodexHomevalues are refused withinvalid_reply_uri. - Conformance fixture case shared with the Python reference.
Scope and limitations
The selected home is still subject to live-writer verification, so the impact is a confusing refusal or a wrong home candidate rather than silent delivery elsewhere. Parity gap with the Python v1 contract.
Checked
- Searched existing issues in this repository and in abruption/session-peer for duplicates.
- Removed credentials, conversation contents, private paths and real device/session identifiers.
- Used isolated fixtures without weakening inbound permissions.
Activity
fix: harden Codex delivery, CLI parsing, SSH and output (#49-#57) (#62)