GHSA-j828-28rj-hfhp: vLLM vulnerable to Regular Expression Denial of Service
4.3
Basic Information
Technical Details
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
vllm | pip | >= 0.6.3, < 0.9.0 | 0.9.0 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability is a series of Regular Expression Denial of Service (ReDoS) issues in the vLLM codebase. Specific regex patterns used with Python's standard re
module were susceptible to catastrophic backtracking when processing crafted inputs. The fix, implemented in commit 4fc1bf813ad80172c1db31264beaef7d93fe0601
, involves replacing the re
module with the regex
library, which generally offers better performance and protection against ReDoS for problematic patterns.
The vulnerable functions were identified by correlating the file paths and line numbers provided in the vulnerability description (referring to commit 2858830c39da0ae153bc1328dbba7680f5fbebe1
) with the changes in the fix commit. Since direct inspection of the vulnerable commit's file content via available tools failed, the function names (except for _eval_correctness_json
, which was clearly identifiable from the patch context) were inferred by examining the current main
branch of the vllm-project/vllm
repository at the specified line numbers. This inference assumes that the function signatures and general code structure around these lines have remained relatively stable. The confidence level for these inferred names is 'medium'.
Each identified function utilized one of the problematic regex patterns cited in the advisory, making it a point where a ReDoS attack could be triggered, leading to significant performance degradation.