Skip to content

Add HTTP/2 fallback for SSH tunnels - #61964

Merged
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/a1cde88dff7a4e5e6574cf12eacb453551f01b72
Nov 17, 2026
Merged

copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/a1cde88dff7a4e5e6574cf12eacb453551f01b72

Conversation

@copyberry

@copyberry copyberry Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Add HTTP/2 fallback for SSH tunnels

Why

SSH tunnels need a working transport when UDP is blocked or a QUIC connection cannot complete an HTTP/3 CONNECT request.

What changed

  • Race TLS HTTP/2 CONNECT against HTTP/3 after a 250 ms QUIC head start, selecting the first successful CONNECT response.
  • Verify the gateway before obtaining credentials, treat CONNECT rejection as terminal, and include admission in the setup timeout.
  • Preserve bounded buffering, TCP half-close behavior, and SSH exit on remote EOF over HTTP/2. Keep peer-supplied debug text out of SSH errors.

Testing

Add local TLS HTTP/2 and HTTP/3 peer tests for transport selection, blocked UDP, stalled HTTP/3, terminal rejection, setup deadlines, certificate verification, address retries, and bidirectional forwarding with both half-close orders.

## Why

SSH tunnels need a working transport when UDP is blocked or a QUIC connection cannot complete an HTTP/3 CONNECT request.

## What changed

- Race TLS HTTP/2 CONNECT against HTTP/3 after a 250 ms QUIC head start, selecting the first successful CONNECT response.
- Verify the gateway before obtaining credentials, treat CONNECT rejection as terminal, and include admission in the setup timeout.
- Preserve bounded buffering, TCP half-close behavior, and SSH exit on remote EOF over HTTP/2. Keep peer-supplied debug text out of SSH errors.

## Testing

Add local TLS HTTP/2 and HTTP/3 peer tests for transport selection, blocked UDP, stalled HTTP/3, terminal rejection, setup deadlines, certificate verification, address retries, and bidirectional forwarding with both half-close orders.

GitOrigin-RevId: a1cde88dff7a4e5e6574cf12eacb453551f01b72
@copyberry
copyberry Bot force-pushed the copyberry/codex-internal-to-codex-oss/a1cde88dff7a4e5e6574cf12eacb453551f01b72 branch from 7e86849 to c8d1ba8 Compare November 17, 2026 04:42
@chatgpt-codex-connector

Copy link
Copy Markdown
Contributor
Codex Review Summary: 🔄 Running

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review 🔄 Running since 2026-11-17T04:42:04.488995Z 7e86849 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@copyberry
copyberry Bot merged commit c8d1ba8 into main Nov 17, 2026
10 of 23 checks passed
@copyberry
copyberry Bot deleted the copyberry/codex-internal-to-codex-oss/a1cde88dff7a4e5e6574cf12eacb453551f01b72 branch November 17, 2026 04:42
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 17, 2026

This branch was previously deployed

1 inactive deployment
issue-triage — c8d1ba81 Deployed Nov 17, 2026 by LiuYangArt via Translate non-English issue #26352
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants