fix(http11): disable retryable HTTP/2 fallback path#2437
fix(http11): disable retryable HTTP/2 fallback path#2437Tianlin0725 wants to merge 1 commit intoprojectdiscovery:devfrom
Conversation
Neo - PR Security ReviewNo security issues found Highlights
Comment |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
WalkthroughAdds conditional cleanup to disable the secondary HTTP/2 client when the HTTP protocol is configured as HTTP/1.1, preventing HTTP/2 fallback behavior. A corresponding test validates this behavior by asserting the secondary client is nil when HTTP/1.1 is selected. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Proposed Changes
Honor explicit
-pr http11intent by disabling retryable HTTP/2 fallback client in httpx.GODEBUG=http2client=0+TLSNextProtooverride).httpx.client.HTTPClient2 = nilwhen protocol ishttp11so retryablehttp-go cannot silently switch to HTTP/2 fallback path.TestHTTP11ShouldDisableRetryableHTTP2Fallback.Proof
Repro/failing behavior before fix
Added test:
Before fix:
After fix:
/claim #2240
Summary by CodeRabbit