Skip to content

fix(header): prevent ReDoS in header value splitting - #21

Merged
spaceone merged 3 commits into
masterfrom
fix/quadratic-redos
Nov 26, 2026
Merged

spaceone merged 3 commits into
masterfrom
fix/quadratic-redos

Conversation

@spaceone

Copy link
Copy Markdown
Owner

Replace the nested, backtracking regular expressions used to split
comma-delimited header elements and semicolon-delimited parameters with
a linear quote-aware scanner. Honor escaped bytes inside quoted strings
while preserving trimming, empty elements, and parameter parsing behavior.

Fixes: GHSA-cwh3-92pm-wf66

Replace the nested, backtracking regular expressions used to split
comma-delimited header elements and semicolon-delimited parameters with
a linear quote-aware scanner. Honor escaped bytes inside quoted strings
while preserving trimming, empty elements, and parameter parsing behavior.

Fixes: GHSA-cwh3-92pm-wf66
@codecov

codecov Bot commented Nov 26, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.86%. Comparing base (2f26e0b) to head (49a65d9).
⚠️ Report is 3 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master      #21      +/-   ##
==========================================
+ Coverage   95.84%   95.86%   +0.02%     
==========================================
  Files          65       65              
  Lines        3850     3870      +20     
==========================================
+ Hits         3690     3710      +20     
  Misses        160      160              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@spaceone
spaceone merged commit 6ca87c9 into master Nov 26, 2026
8 checks passed
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.

1 participant