Skip to main content
Vulnerability Database/CVE-2026-94635

CVE-2026-94635: Apache Thrift Lua Bindings DoS Vulnerability

CVE-2026-94635 is a denial of service vulnerability in Apache Thrift Lua bindings caused by allocation of resources without limits and improper length handling. This article covers technical details, affected versions, and mitigation.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-94635 Overview

CVE-2026-94635 is a resource exhaustion vulnerability in the Lua bindings of Apache Thrift. The flaw stems from allocation of resources without limits or throttling, combined with improper handling of length parameter inconsistency [CWE-130]. Attackers can send crafted Thrift messages over the network to trigger excessive memory allocation in Lua-based Thrift servers and clients. The issue affects all Apache Thrift releases before version 0.25.0. Apache has released version 0.25.0 to resolve the vulnerability.

Critical Impact

Unauthenticated remote attackers can trigger denial-of-service conditions in Lua-based Apache Thrift deployments by exploiting length parameter handling in deserialization.

Affected Products

  • Apache Thrift Lua bindings, all versions before 0.25.0
  • Lua-based services and clients using Thrift serialization
  • Downstream applications bundling vulnerable Thrift Lua libraries

Discovery Timeline

  • 2026-10-02 - CVE-2026-94635 published to the National Vulnerability Database (NVD)
  • 2026-10-02 - Last updated in NVD database

Technical Details for CVE-2026-94635

Vulnerability Analysis

The vulnerability resides in the Apache Thrift Lua bindings, which implement serialization and deserialization for Thrift's binary and compact protocols. When processing incoming messages, the Lua code reads length fields from the wire that describe the size of upcoming collections, strings, or binary buffers. The implementation does not validate these length values against actual payload size or impose upper bounds.

A remote attacker can declare a very large length value in a Thrift message while supplying a small or empty payload. The Lua runtime attempts to allocate memory proportional to the declared length, which exhausts process memory and causes service termination. The flaw is network-reachable and requires no authentication or user interaction.

Root Cause

The root cause maps to [CWE-130: Improper Handling of Length Parameter Inconsistency]. Deserialization routines in the Lua bindings trust client-supplied length prefixes without cross-checking them against the remaining bytes available in the message buffer. The absence of allocation caps compounds the issue, allowing a single malformed frame to request gigabyte-scale allocations.

Attack Vector

An attacker crafts a Thrift message with inflated length prefixes for list, map, set, string, or binary fields. The attacker sends the message to any exposed Thrift endpoint using the Lua implementation. The target process attempts the oversized allocation and either crashes with an out-of-memory error or becomes unresponsive. Repeated requests sustain the denial-of-service condition against clustered services.

Technical details are available in the Apache Thread Discussion and the Apache Thread Update.

Detection Methods for CVE-2026-94635

Indicators of Compromise

  • Lua Thrift processes terminating with out-of-memory errors or lua_Alloc failures in service logs
  • Sudden memory pressure or OOM-killer activity on hosts running Thrift Lua endpoints
  • Repeated short-lived TCP connections to Thrift ports followed by server restarts
  • Thrift frames where declared field lengths vastly exceed the TCP payload size observed on the wire

Detection Strategies

  • Inventory services linking the Apache Thrift Lua runtime and record their versions against the 0.25.0 baseline
  • Deploy protocol-aware inspection that compares Thrift length prefixes against actual frame size
  • Correlate process-crash events with inbound Thrift traffic bursts in centralized logging

Monitoring Recommendations

  • Alert on resident set size growth exceeding configured thresholds for Thrift Lua workers
  • Track Thrift request rate per source IP and flag anomalous connection patterns
  • Monitor service restart counts and OOM-killer entries in dmesg or systemd journals

How to Mitigate CVE-2026-94635

Immediate Actions Required

  • Upgrade Apache Thrift to version 0.25.0 or later across all Lua-based deployments
  • Identify third-party packages that embed older Thrift Lua libraries and update them
  • Restrict network exposure of Thrift endpoints to trusted clients using firewall rules or service mesh policy
  • Enable per-process memory limits via ulimit or container resource constraints to contain exploitation

Patch Information

Apache Thrift version 0.25.0 fixes the vulnerability by validating length parameters and bounding allocations in the Lua bindings. Review the Apache Thread Discussion and the Apache Thread Update for release details and migration guidance.

Workarounds

  • Place Thrift Lua services behind a reverse proxy that enforces maximum request body size
  • Terminate TLS and inspect Thrift traffic at an application gateway capable of frame-size validation
  • Apply strict ingress rate limits on Thrift listener ports to reduce exploitation throughput
  • Run Thrift processes under cgroup memory limits so single-request exhaustion does not destabilize the host
bash
# Configuration example: enforce memory limits for Thrift Lua workers via systemd
[Service]
MemoryMax=512M
MemoryHigh=400M
LimitAS=536870912
Restart=on-failure

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.