Skip to content

Desktop Connect: handle Cloudflare zstd-compressed pairing responses safely #2245

Closed

Description

@integry

Real desktop acceptance exposed a likely transport incompatibility. Target desktop epic 1950-epic-cross-platform-dsk, NOT main. Keep this bounded; no production deployment or Windows work.

Evidence: actual Electron desktop connected to an approved isolated Cloudflare-managed t-*.propr.dev tunnel. Browser approval succeeded through an isolated epic UI preview. API pairing row became approved and provisional_token_id was populated at 13:42:04.469Z, but desktop logged PAIRING_REJECTED at 13:42:04.514Z; activation never completed. Public tunnel discovery requested with Accept-Encoding: gzip, deflate, br, zstd returns HTTP200 application/json and Content-Encoding: zstd. Desktop uses session.defaultSession.fetch. packages/client/src/pairingProtocol.ts contentEncoding only permits identity/gzip/br and rejects zstd. This is a likely cause requiring reproduction, not permission to weaken response validation.

Implement safe interoperability for real Chromium/Electron negotiated compression (support bounded transparently decoded zstd where appropriate, or explicitly constrain negotiation safely). Preserve strict JSON/type/schema/binding checks, decoded and wire byte limits, redirects, deadlines, cancellation/body cleanup, and rejection of malformed/stacked/unsupported encodings. Add focused regression coverage plus native Electron evidence that the selected approach works across the actual Fetch boundary, not merely a fabricated Response. No secrets in tests/logs/comments; do not use real test credentials.

Use Ultrafix first and report results; leave PR unmerged for independent review. PR body must use Closes #. Related acceptance #1962, epic #1970. Root will repeat real tunnel pairing after integration. Browser-launcher isolation and hosted-UI deployment are separate from this task.

Activity

  1. propr-dev commented on Sep 9, 2026

    @propr-dev
    Contributor

    🤖 AI processing has started for this issue using codex agent with gpt-5.6-sol model.

    I'll analyze the problem and work on a solution. This may take a few minutes.

    Processing Details:

    • Agent: codex
    • Model: gpt-5.6-sol
    • Branch: 2245/gpt-5.6-sol-desktop-connect-handle-cl-20260909-1345-j8o
    • Base Branch: 1950-epic-cross-platform-dsk
    • Worktree: issue-2245-20260909-1345-gpt-5.6-sol-j8o

    🔍 Track Task Execution

  2. added a commit that references this issue on Sep 9, 2026
  3. integry commented on Sep 9, 2026

    @integry
    OwnerAuthor

    Implemented and merged into desktop epic 1950-epic-cross-platform-dsk by PR #2246 (merge f5a8911). Explicitly closing because the epic is not the default branch. ProPR review found no code blockers; independent 15/15 focused tests, Linux package build/fuse inspection, full suite and all four Linux/macOS package checks passed. Windows remains deferred under #2074. Live tunnel pairing acceptance continues in #1962.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions