CVE-2020-23311

7.5 HIGH

📋 TL;DR

CVE-2020-23311 is an assertion failure vulnerability in JerryScript's JavaScript parser that can cause denial of service through application crashes. Attackers can trigger this by providing specially crafted JavaScript input to applications using vulnerable JerryScript versions. This affects any system running applications that embed JerryScript 2.2.0 for JavaScript execution.

💻 Affected Systems

Products:
  • JerryScript
Versions: Version 2.2.0
Operating Systems: All operating systems running JerryScript
Default Config Vulnerable: ⚠️ Yes
Notes: Any application embedding JerryScript 2.2.0 for JavaScript execution is vulnerable when processing JavaScript input.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Remote code execution leading to complete system compromise if the assertion failure can be leveraged for memory corruption attacks.

🟠

Likely Case

Denial of service through application crashes when processing malicious JavaScript input.

🟢

If Mitigated

Limited impact with proper input validation and sandboxing of JavaScript execution environments.

🌐 Internet-Facing: MEDIUM - Applications accepting untrusted JavaScript input from external sources are vulnerable to DoS attacks.
🏢 Internal Only: LOW - Internal applications with controlled JavaScript input sources face minimal risk.

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: LIKELY
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Proof of concept demonstrates triggering the assertion failure with specific JavaScript syntax. Exploitation requires ability to provide JavaScript input to vulnerable applications.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: JerryScript 2.3.0 and later

Vendor Advisory: https://github.com/jerryscript-project/jerryscript/issues/3822

Restart Required: Yes

Instructions:

1. Upgrade JerryScript to version 2.3.0 or later. 2. Rebuild any applications using JerryScript. 3. Restart affected services.

🔧 Temporary Workarounds

Input Validation

all

Implement strict input validation to reject malformed JavaScript before processing by JerryScript.

Sandbox JavaScript Execution

all

Run JerryScript in isolated containers or sandboxes to limit impact of crashes.

🧯 If You Can't Patch

  • Implement network segmentation to isolate systems running vulnerable JerryScript versions
  • Deploy web application firewalls to filter malicious JavaScript input patterns

🔍 How to Verify

Check if Vulnerable:

Check if applications use JerryScript version 2.2.0 by examining dependencies or running 'strings' on binaries for JerryScript version identifiers.

Check Version:

Check application documentation or build configuration for JerryScript version, or use: grep -r 'jerry' /path/to/application/ | grep -i version

Verify Fix Applied:

Verify JerryScript version is 2.3.0 or later and test with known proof-of-concept inputs that previously caused crashes.

📡 Detection & Monitoring

Log Indicators:

  • Application crashes with JerryScript assertion failures
  • Error messages containing 'js-parser-expr.c:3230' or 'parser_parse_object_initializer'

Network Indicators:

  • Unusual JavaScript payloads in HTTP requests or other input channels

SIEM Query:

source="application.logs" AND ("assertion failed" OR "jerryscript" OR "js-parser-expr.c")

🔗 References

📤 Share & Export