Skip to content

fix: plain HTTP requests through the HTTP proxy cut off after 10 seconds - #1676

Merged
tobyxdd merged 1 commit into
masterfrom
fix/http-proxy-body-timeout
Sep 6, 2026
Merged

fix: plain HTTP requests through the HTTP proxy cut off after 10 seconds#1676
tobyxdd merged 1 commit into
masterfrom
fix/http-proxy-body-timeout

Conversation

@tobyxdd

@tobyxdd tobyxdd commented Sep 6, 2026

Copy link
Copy Markdown
Collaborator

Fixes #1674

The client's HTTP inbound fetched plain http:// URLs with an http.Client that had Timeout: 10s. That field is a wall-clock limit on the entire exchange, including reading the body — so any response taking longer than 10 s to stream was cancelled mid-transfer, regardless of progress. CONNECT and SOCKS5 were unaffected as they don't go through this client.

Replace it with Transport.ResponseHeaderTimeout, which bounds only the dial and the wait for response headers. The body can now take as long as it takes, matching how the HTTP/SOCKS5 outbounds already scope their handshake deadlines.

@tobyxdd
tobyxdd merged commit 955a482 into master Sep 6, 2026
1 check passed
@tobyxdd
tobyxdd deleted the fix/http-proxy-body-timeout branch September 6, 2026 19:05
zhkl0228 added a commit to zhkl0228/hysteria that referenced this pull request Sep 10, 2026
上游 HyNetworks#1676:修复经 HTTP 代理的明文 HTTP 请求在 10 秒后被切断。
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

HTTP inbound: plain HTTP (non-CONNECT) streams killed at almost exactly 10 seconds (v2.12.2)

1 participant