CVE-2026-69219: RabbitMQ Java client ValueReader: Oversized LongString/bytes length triggers OOM via unchecked allocation

Published Aug 18, 2026
·
Updated

Summary

ValueReader.readBytes() allocates a byte array sized by a wire-declared content length without validating it against actual frame data. A malicious AMQP peer triggers OOM by declaring a ~2GB string/bytes field.

Vulnerable Code

src/main/java/com/rabbitmq/client/impl/ValueReader.java lines 83-95:

java private static byte[] readBytes(final DataInputStream in) throws IOException { final long contentLength = unsignedExtend(in.readInt()); if(contentLength < Integer.MAXVALUE) { final byte[] buffer = new byte[(int)contentLength]; // allocates before reading in.readFully(buffer); return buffer; } }

Attack Scenario

A malicious AMQP server sends a LongString field (type tag 'S') with declared length 0x7FFFFFFE (2,147,483,646). The check contentLength < Integer.MAXVALUE passes. new byte[2147483646] attempts ~2GB allocation, causing OutOfMemoryError before readFully() attempts to read data.

The allocation size is attacker-controlled and is NOT validated against the frame size or TruncatedInputStream bounds. Exploitable pre-authentication via connection.start server-properties table.

Impact

Denial of service via JVM OutOfMemoryError. Crashes the entire JVM.

CWE

CWE-789: Memory Allocation with Excessive Size Value

Remediation

Validate contentLength against the frame's remaining bytes or the negotiated max frame size (default 131,072) before allocating.

Other sources

The RabbitMQ Java client library allows Java and JVM-based applications to connect to and interact with RabbitMQ nodes. Prior to 5.33.1, src/main/java/com/rabbitmq/client/impl/ValueReader.java uses ValueReader.readBytes to accept a wire-declared contentLength below Integer.MAXVALUE and allocate a byte array before checking the bytes available in the frame. A malicious AMQP peer can send a LongString or byte-array field with type tag S and a declared length such as 0x7FFFFFFE during the pre-authentication connection.start server-properties table, causing an approximately 2 GB allocation and OutOfMemoryError before readFully consumes data. The resulting memory exhaustion can terminate the JVM and cause denial of service. This issue is fixed in version 5.33.1.

MITRE

Affected Software

2 affected componentsFixes available
RabbitMQ RabbitMQ Java client<5.33.1
maven/com.rabbitmq:amqp-client<=5.33.0
5.33.1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade maven/com.rabbitmq:amqp-client to a version that resolves this vulnerability.

    Fixed in 5.33.1
  2. Upgrade

    Upgrade RabbitMQ Java client (com/rabbitmq/client) to a version that resolves this vulnerability.

    Fixed in 5.33.1
  3. Compensating control

    Mitigate pre-authentication DoS by limiting network access to the AMQP service (e.g., firewall/ACL restrictions so untrusted peers cannot reach the RabbitMQ node’s AMQP port).

Event History

Aug 18, 2026
CVE Published
via MITRE·04:23 PM
Data Sourced
via MITRE·04:23 PM
DescriptionWeakness
Advisory Published
via GitHub·04:32 PM
Data Sourced
via GitHub·04:32 PM
DescriptionWeaknessAffected Software

Frequently Asked Questions

1

Which deployments are realistically exposed?

Java and JVM-based applications using RabbitMQ Java client versions earlier than 5.33.1 are exposed when they connect to a malicious AMQP peer. The issue can be triggered during the pre-authentication connection.start exchange, before client credentials are processed.

2

What does an attacker need to exploit this?

An attacker needs to operate, impersonate, or otherwise cause the client to connect to a malicious AMQP peer that sends a crafted server-properties table. No authentication is required because the malformed LongString or byte-array field is processed before authentication.

3

What should be done to remediate the issue?

Upgrade the RabbitMQ Java client to version 5.33.1, which fixes the unchecked allocation behavior. The provided data does not identify a separate configuration workaround.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203