CVE-2021-24044CWE-843

By passing invalid javascript code where await and yield were called upon non-async and non-generator getter/setter functions, Hermes would invoke generator…

published January 15, 2022

CVSS
—
EPSS
1%
Percentile
69.4
In the wild
Unconfirmed
What it is

⚠️ A rogue JavaScript snippet can cause a segmentation fault! By messing with Hermes' async functions, attackers can trigger unexpected crashes — think of it as a sneaky prank that goes horribly wrong. 🔥 Imagine a restaurant where the chef suddenly tries to cook with expired ingredients that don't belong in the recipe. The meal ends up chaotic, leading to kitchen disasters and a disgruntled dining experience — that's what happens when invalid JavaScript interacts with non-async functions in Hermes! While the chances of Remote Code Execution (RCE) are low, a well-timed invalid code can still lead to a segmentation fault, crashing applications unexpectedly. This could disrupt services and frustrate users, making it a surprisingly sneaky issue to overlook.

Put simply

Imagine a restaurant where the chef suddenly tries to cook with expired ingredients that don't belong in the recipe. The meal ends up chaotic, leading to kitchen disasters and a disgruntled dining experience — that's what happens when invalid JavaScript interacts with non-async functions in Hermes! This vulnerability occurs in Hermes versions prior to v0.10.0, where invalid JavaScript code can invoke generator functions incorrectly via await and yield calls on non-async/non-generator getters/setters, leading to type confusion errors.

What to do

While the chances of Remote Code Execution (RCE) are low, a well-timed invalid code can still lead to a segmentation fault, crashing applications unexpectedly. This could disrupt services and frustrate users, making it a surprisingly sneaky issue to overlook. To protect your applications, update Hermes to version v0.10.0 or later immediately. Additionally, review your JavaScript code to ensure valid async patterns are consistently applied, reducing the risk of triggering this error. 🛡️ You've got this! Follow these steps, and you'll keep your systems running smoothly! 🌟

The record
Technical detail
CVSS
Not scored
CVSS v4.0
Not supplied
EPSS
0.01260 · 69.4th percentile
Weakness
CWE-843 · Access of Resource Using Incompatible Type ('Type Confusion')
Published
2022-01-15T00:35Z
EPSS history
Timeline
  • 15 JAN 00:35Z
    By passing invalid javascript code where await and yield were called upon non-async and non-generator getter/setter functions, Hermes would invoke generator…
    cvelistv5