CVE-2024-25176

LuaJIT through 2.1 and OpenRusty luajit2 before v2.1-20240626 have a stack-buffer-overflow in lj_strfmt_wfnum in lj_strfmt_num.c

Critical Β· published July 7, 2025

CVSS v3.1
9.8
EPSS
1%
Percentile
48.0
In the wild
Unconfirmed
What it is

πŸ”₯ A stack-buffer-overflow lurking in LuaJIT could let attackers run amok, and it’s not something you want in your code! 🚨 Think of this vulnerability like a car with a faulty brake system β€” one tiny miscalculation can send everything crashing down. If an attacker exploits this flaw, they can manipulate memory and run malicious code, much like a reckless driver taking control of the steering wheel. This critical vulnerability could lead to devastating consequences, allowing an attacker to execute arbitrary code within your application. With the right input, they could potentially hijack processes, corrupt data, or even crash your system entirely β€” a real nightmare scenario for any developer!

Put simply

Think of this vulnerability like a car with a faulty brake system β€” one tiny miscalculation can send everything crashing down. If an attacker exploits this flaw, they can manipulate memory and run malicious code, much like a reckless driver taking control of the steering wheel. The stack-buffer-overflow occurs in lj_strfmt_wfnum within lj_strfmt_num.c, where improper handling of formatted numbers can lead to memory corruption. This flaw is present in LuaJIT versions through 2.1 and OpenRusty luajit2 before v2.1-20240626.

What to do

This critical vulnerability could lead to devastating consequences, allowing an attacker to execute arbitrary code within your application. With the right input, they could potentially hijack processes, corrupt data, or even crash your system entirely β€” a real nightmare scenario for any developer! To secure your systems, immediately upgrade to LuaJIT version 2.1-20240626 or later. Make sure to review your code for any additional potential vulnerabilities and consider implementing additional security measures like input validation and buffer overflow protections. You've got this! Implement these fixes and your code will be back on the road to safety in no time. πŸ›‘οΈ

The record
Technical detail
CVSS v3.1
9.8 Β· CRITICAL
Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CVSS v4.0
Not supplied
EPSS
0.00599 Β· 48.0th percentile
Published
2025-07-07T00:00Z
EPSS history
Timeline
  • 07 JUL 00:00Z
    LuaJIT through 2.1 and OpenRusty luajit2 before v2.1-20240626 have a stack-buffer-overflow in lj_strfmt_wfnum in lj_strfmt_num.c
    cvelistv5