Fix HTTP redirect boundary limit issue#7065
Fix HTTP redirect boundary limit issue#7065dei96303-boop wants to merge 2 commits intoprojectdiscovery:devfrom
Conversation
Neo - PR Security ReviewNo security issues found Highlights
Hardening Notes
Comment |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review infoConfiguration used: Organization UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (2)
WalkthroughSmall, focused edits: stricter redirect boundary check in the HTTP client pool, direct struct literal creation for MetaInput in the list provider, and a new Context helper method CloneWithIP that returns a context copy with its MetaInput.CustomIP set. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 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 |
Fixes #5835
Description
Updated the
checkMaxRedirectsfunction inpkg/protocols/http/httpclientpool/clientpool.goto use>=instead of>when checking the redirect limit. This ensures the client stops exactly at themaxRedirectslimit, preventing unnecessary extra requests and potential infinite loops.Changes Made
len(via) > defaultMaxRedirectstolen(via) >= defaultMaxRedirectslen(via) > maxRedirectstolen(via) >= maxRedirectsSummary by CodeRabbit
Bug Fixes
New Features