CVE-2021-44994
Medium · 5.5CVSS
5.5
EPSS
1.0%
Published
Jan 25, 2022
CISA due date
—
Cloudanix analysis
A flaw in a JavaScript processing tool can make apps using it crash unexpectedly from bad input.
- Exploitation
- Requires User Interaction
- Attacker needs
- User Interaction
- Complexity
- Low
- Impact
- Denial Of Service
- Component
- Library
- Class
- Denial of service
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
Triggers an assertion failure in the memory heap management of the Jerryscript JavaScript engine, causing the process to terminate.
Why it matters to the business
Leads to unexpected crashes in applications relying on Jerryscript, disrupting services especially in resource-constrained environments like IoT devices.
How an attack unfolds
An attacker supplies specially crafted JavaScript input to the engine that violates the heap allocation invariant, triggering the failed assertion and crashing the application.
How to fix it
No fixed versions listed; monitor for updates to Jerryscript or apply patches to remove or handle the assertion gracefully.
How to confirm the fix worked
Test with inputs that previously triggered the crash to ensure stability; check for absence of the assertion failure in logs.
Typical attack path
- Identify an application using the vulnerable Jerryscript version
- Craft malicious JavaScript code to trigger heap assertion
- Deliver the input to the target application
- Cause denial of service through crash
How to detect it
Look for application crash logs containing the assertion failure message from jmem-heap.c; monitor for unexpected terminations of processes using Jerryscript.
- JERRY_CONTEXT (jmem_heap_allocated_size) == 0
- /jerry-core/jmem/jmem-heap.c
- Assertion failed
What your security team should do
- Assess usage of Jerryscript in the environment
- Plan for updates once available
- Implement input validation to mitigate potential triggers
- Monitor for crashes related to the engine
The record
There is an Assertion ''JERRY_CONTEXT (jmem_heap_allocated_size) == 0'' failed at /jerry-core/jmem/jmem-heap.c in Jerryscript 3.0.0.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Ubuntu:22.04:LTS | iotjs | 0 | No fix |
| conan | jerryscript | 3.0.0 | No fix |
Related vulnerabilities
- CVE-2024-33255 Jerryscript commit cefd391 was discovered to contain an Assertion Failure via… Also affects iotjs
- CVE-2024-33260 Jerryscript commit cefd391 was discovered to contain a segmentation violation via the… Also affects iotjs
- CVE-2024-33258 Jerryscript commit ff9ff8f was discovered to contain a segmentation violation via the… Also affects iotjs
- CVE-2024-33259 Jerryscript commit cefd391 was discovered to contain a segmentation violation via the… Also affects iotjs
- CVE-2023-36109 Buffer Overflow vulnerability in JerryScript version 3.0, allows remote attackers to… Also affects iotjs
- CVE-2023-38961 Buffer Overflwo vulnerability in JerryScript Project jerryscript v.3.0.0 allows a remote… Also affects iotjs
- CVE-2023-36201 An issue in JerryscriptProject jerryscript v.3.0.0 allows an attacker to obtain sensitive… Also affects iotjs
- CVE-2023-34867 Jerryscript 3.0 (commit 05dbbd1) was discovered to contain an Assertion Failure via the… Also affects iotjs