CVE-2024-36760:
Rhai stack overflow vulenrability
7.5
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.44011%
CWE
Published
6/13/2024
Updated
8/4/2024
KEV Status
No
Technology
Rust
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
rhai | rust | <= 1.18.0 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from missing recursion depth management in function call handling. The commit diff shows 'defer!' blocks added to increment a 'global.level' counter in 4 locations within src/func/call.rs, indicating these were points where recursive calls weren't properly tracked. The stack trace shows repeated calls between eval_stmt_block and call_script_fn, while the test case demonstrates recursion through closure methods. Both functions are part of the call chain that failed to enforce recursion limits, making them root causes.