GHSA-93j5-89vc-pph4 — amqp-client
Fix: rabbitmq/rabbitmq-java-client#2007GHSA-93j5-89vc-pph4 is a CWE-674 vulnerability in com.rabbitmq:amqp-client. A fix is available for com.rabbitmq:amqp-client — see the affected versions and patch details below.
RabbitMQ Java client ValueReader: Unbounded recursive table/array nesting causes StackOverflowError DoS
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
Real-World Exposure
com.rabbitmq:amqp-clientReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Maven packages — download data is not available via public APIs for these ecosystems.
Description
Summary
ValueReader.readTable() and readArray() recursively call readFieldValue() with no depth limit. A malicious AMQP peer can crash the client JVM by sending a deeply nested table structure.
Vulnerable Code
src/main/java/com/rabbitmq/client/impl/ValueReader.java lines 139-155 and 237-249:
private static Map<String, Object> readTable(DataInputStream in) throws IOException {
long tableLength = unsignedExtend(in.readInt());
// ...
while(tableIn.available() > 0) {
String name = readShortstr(tableIn);
Object value = readFieldValue(tableIn); // recursive call
}
}
static Object readFieldValue(DataInputStream in) throws IOException {
switch(in.readUnsignedByte()) {
case 'F': value = readTable(in); // mutual recursion
case 'A': value = readArray(in); // mutual recursion
}
}
Attack Scenario
A malicious AMQP server (or MitM) sends a connection.start frame with ~580 levels of nested tables. Each level costs ~7 bytes (4-byte length + 1-byte key length + 1-byte key + 1-byte type tag), totaling ~4060 bytes within the 131,072 byte max frame size. With the default JVM stack (~512KB, ~864 bytes/frame), this triggers StackOverflowError, killing the I/O thread.
Exploitable pre-authentication since connection.start is the very first server frame.
Impact
Denial of service. StackOverflowError kills the client I/O thread.
CWE
CWE-674: Uncontrolled Recursion
Remediation
Add a depth counter to readTable/readArray/readFieldValue and throw MalformedFrameException when exceeding a threshold (e.g., 32).
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| ☕Maven | com.rabbitmq:amqp-client | all versions | 5.33.1com.rabbitmq:amqp-client:5.33.1 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for com.rabbitmq:amqp-client, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update com.rabbitmq:amqp-client to 5.33.1 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-93j5-89vc-pph4 is resolved across your whole dependency graph.
Workarounds
Stop feeding it untrusted input: reject or quarantine files and payloads from unverified sources until you can upgrade, restrict accepted formats to the ones you actually need, and run the parsing or decoding step in a least-privileged sandbox or short-lived worker so a crash or corrupted read cannot reach the rest of the process.
Frequently Asked Questions
Is GHSA-93j5-89vc-pph4 in your dependencies?
Find it across Maven, including transitive dependencies.