RabbitMQ amqp091-go: Consumer Message Flooding via Signed-to-Unsigned Integer Casting in Qos Configuration
## Summary A logic and resource exhaustion vulnerability exists in the AMQP client's Quality of Service (`Qos`) configuration method. The `Qos` function accepts signed integers (`int`) for the `prefetchCount` and `prefetchSize` parameters but casts them directly to unsigned integers (`uint16` and `uint32`, respectively) when formatting the wire-level frame. If a developer passes a negative integer (such as `-1`) to these parameters—frequently intended as a sentinel value meaning "no change" or "no limit"—the application performs an implicit signed-to-unsigned conversion. This wraps the values to their absolute maximum limit ($65535$ and $4294967295$). Consequently, a consumer expecting restricted message delivery rates is suddenly flooded with an unlimited volume of messages, potentially exhausting memory resources and crashing the application. --- ## Vulnerability Details ### Mechanism The bug manifests during the structural assignment inside the channel's `Qos` method: ```go // channel.go:795-796 PrefetchCount: uint16(prefetchCount), // -1 wraps to 65535 PrefetchSize: uint32(prefetchSize), // -1 wraps to 4294967295 ``` In Go, converting a negative signed integer to an unsigned integer shifts the value via two's complement arithmetic. Because no boundary validation or signedness check occurs prior to the cast: * Passing `-1` for `prefetchCount` yields a wire value of `65535`. * Passing `-1` for `prefetchSize` yields a wire value of `4294967295`. ### Impact The AMQP broker in
GHSA-rm6m-hrcw-jw33
Primary source · Revision 1
Imported from structured advisory data. Source references identify upstream records or fields; verify affected versions and your deployed configuration.
Security context
Source reference: osv:GHSA-rm6m-hrcw-jw33
github.com/rabbitmq/amqp091-go
Source reference: /affected/0/package/name
- Affected versions
- Not stated in this record
- Fixed versions
- 1.13.0
Source reference:
/affected/0/ranges - Prerequisites
- Not stated in this record
Structured affected-version data
Original package identities and version rules from this source.
[
{
"ranges": [
{
"type": "SEMVER",
"events": [
{
"introduced": "0"
},
{
"fixed": "1.13.0"
}
]
}
],
"package": {
"name": "github.com/rabbitmq/amqp091-go",
"purl": "pkg:golang/github.com/rabbitmq/amqp091-go",
"ecosystem": "Go"
},
"database_specific": {
"source": "https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/09/GHSA-rm6m-hrcw-jw33/GHSA-rm6m-hrcw-jw33.json"
}
}
]- Related CVEs
- CVE-2026-77406
Source reference:
/aliases
Publisher severity
high
Source reference: /database_specific/severity
- Event
- #63946 · Revision 1
- Added to Heist Feed
- Publisher date
GO-2026-6502
Revision 2
RabbitMQ amqp091-go: Consumer Message Flooding via Signed-to-Unsigned Integer Casting in Qos Configuration in github.com/rabbitmq/amqp091-go
RabbitMQ amqp091-go: Consumer Message Flooding via Signed-to-Unsigned Integer Casting in Qos Configuration in github.com/rabbitmq/amqp091-go
Imported from structured advisory data. Source references identify upstream records or fields; verify affected versions and your deployed configuration.
Security context
Source reference: osv:GO-2026-6502
github.com/rabbitmq/amqp091-go
Source reference: /affected/0/package/name
- Affected versions
- Not stated in this record
- Fixed versions
- 1.13.0
Source reference:
/affected/0/ranges - Prerequisites
- Not stated in this record
Structured affected-version data
Original package identities and version rules from this source.
[
{
"ranges": [
{
"type": "SEMVER",
"events": [
{
"introduced": "0"
},
{
"fixed": "1.13.0"
}
]
}
],
"package": {
"name": "github.com/rabbitmq/amqp091-go",
"purl": "pkg:golang/github.com/rabbitmq/amqp091-go",
"ecosystem": "Go"
},
"database_specific": {
"source": "https://vuln.go.dev/ID/GO-2026-6502.json"
},
"ecosystem_specific": {
"imports": [
{
"path": "github.com/rabbitmq/amqp091-go",
"symbols": [
"Channel.Qos"
]
}
]
}
}
]- Related CVEs
- CVE-2026-77406
Source reference:
/aliases
Publisher severity
No explicit severity was provided.
- Event
- #63947 · Revision 2
- Added to Heist Feed
- Publisher date