CVE-2026-59404

Denial of Service
Affects
Spring AMQP
in
Spring
No items found.
Versions
<=2.4.19, >=3.0.0 <=3.2.13, >=4.0.0 <=4.0.6, >=4.1.0 <=4.1.2

Patch Available.

Exclamation circle icon
Patch Available

This Vulnerability has been fixed in the Never-Ending Support (NES) version offered by HeroDevs.

Overview

Spring AMQP is the Spring project that provides support for using Spring and Java with AMQP 0.9.1, and in particular RabbitMQ, offering templates for sending and receiving messages and listener containers for message-driven consumers.

A denial of service vulnerability (CVE-2026-59404) has been identified in the message header conversion of Spring AMQP's spring-rabbit module, which allows attackers who can publish to a consumed queue to crash the consumer thread with a single message carrying deeply nested headers. If the broker redelivers the unacknowledged message, the listener container can enter a crash loop.

Per OWASP: The Denial of Service (DoS) attack is focused on making a resource (site, application, server) unavailable for the purpose it was designed.

This issue affects multiple versions of Spring AMQP.

Details

Module Info

Vulnerability Info

This Medium-severity vulnerability is found in the org.springframework.amqp:spring-rabbit package in multiple versions of Spring AMQP.

When a message is received, DefaultMessagePropertiesConverter.toMessageProperties() converts every AMQP header value with convertLongStringIfNecessary(), which turns LongString instances into Java strings. AMQP 0-9-1 field-arrays and field-tables arrive as List and Map values and may nest arbitrarily, so the method walks them recursively, with one stack frame per level and no depth limit:

private Object convertLongStringIfNecessary(Object valueArg, String charset) {
        if (valueArg instanceof LongString longStr) {
                return convertLongString(longStr, charset);
        }

        if (valueArg instanceof List<?> values) {
                List<Object> convertedList = new ArrayList<>(values.size());
                values.forEach(value -> convertedList.add(this.convertLongStringIfNecessary(value, charset)));
                return convertedList;
        }

        if (valueArg instanceof Map<?, ?> originalMap) {
                Map<String, Object> convertedMap = new HashMap<>();
                originalMap.forEach(
                        (key, value) -> convertedMap.put((String) key, this.convertLongStringIfNecessary(value, charset)));
                return convertedMap;
        }

        return valueArg;
}

An attacker who can publish to a queue consumed by a Spring AMQP listener container, or read with RabbitTemplate.receive(), can send a single message whose header contains thousands of nested field-arrays or field-tables, only a few tens of kilobytes on the wire. Converting that header exhausts the stack and throws a StackOverflowError on the consumer thread before any application code sees the message. Because the message is never acknowledged, the broker can redeliver it, and the container fails again on every delivery, so the consumer stops processing messages. Older lines express the same recursion with a loop over the list and map entries rather than lambdas, with the same unbounded depth.

Mitigation

Only recent versions of Spring AMQP receive community support. Older lines are End-of-Life and will not receive public updates to address this issue.

Users of the affected components should apply one of the following mitigations:

  • Upgrade to a currently supported version of Spring AMQP.
  • Leverage a commercial support partner like HeroDevs for post-EOL security support.
Vulnerability Details
Severity
Level
CVSS Assessment
Low
>=0 <4
Medium
>=4 <6
High
>=6 <8
Critical
>=8 <10
Medium
ID
CVE-2026-59404
PROJECT Affected
Spring AMQP
Versions Affected
<=2.4.19, >=3.0.0 <=3.2.13, >=4.0.0 <=4.0.6, >=4.1.0 <=4.1.2
NES Versions Affected
Published date
November 20, 2026
≈ Fix date
Category
Denial of Service
Vex Document
Download VEXHow do I use it?
Sign up for the latest vulnerability alerts fixed in
NES for Spring
Rss feed icon
Subscribe via RSS
or

By submitting the form I acknowledge receipt of our Privacy Policy.

Thanks for signing up for our Newsletter! We look forward to connecting with you.
Oops! Something went wrong while submitting the form.