You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug] SEGV in strtod.h FastPath due to Integer Overflow in Exponent Parsing (v1.0.0) #2406
Root Cause:
During parsing of a floating-point number with an extremely large negative exponent (e.g., -3022222222223), the exponent integer overflows in ParseNumber(). The corrupted exponent is then passed to FastPath(), which calls Pow10(exp). Since the exponent exceeds the valid range, Pow10() accesses the kPow10 array out of bounds, causing a SEGV.
ASan Report:
ERROR: AddressSanitizer: SEGV on unknown address 0x63a13691e668
READ of size 1
#0 FastPath() at strtod.h:31 #1 StrtodNormalPrecision() at strtod.h:43 #2 ParseNumber<0u>() at reader.h:951 #3 Parse<0u>() at reader.h:408
GDB Backtrace:
#0 FastPath() at strtod.h:31 #1 FastPath() at strtod.h:27 #2 StrtodNormalPrecision() at strtod.h:43 #3 ParseNumber<0u>() at reader.h:951
Independence Statement:
This vulnerability is independent from CVE-2024-38517:
Crash point: strtod.h FastPath() vs reader.h ParseNumber()
Crash type: SEGV (OOB read) vs integer underflow
Affected: v1.0.0 only (fixed in v1.0.1+)
Trigger: extremely large negative exponent vs specific integer input
Impact:
Denial of Service (DoS)
Suggested Fix:
Add a range check on the exponent before calling Pow10().
Activity