Predictable direct reply-to key allows cross-peer reply injection
Summary
Summary
Direct reply-to addresses have the form amq.rabbitmq.reply-to.<encoded-pid>.<key>. The key is the capability that authorises delivery to the reply-to consumer — rabbit_queue_type:handle_event/3 matches on the full resource name, so a wrong key delivers nothing. That key is generat...
Affected packages
| Package | Affected → Fixed | |
|---|---|---|
| otherrabbitmq-server |
>= 4.3.0, < 4.3.7→ 4.3.7 |
4.3.7 |
| otherrabbitmq-server |
>= 4.2.0, < 4.2.12→ 4.2.12 |
4.2.12 |
Original description The description as published by the source.
Summary
Direct reply-to addresses have the form amq.rabbitmq.reply-to... The key is the capability that authorises delivery to the reply-to consumer — rabbit_queue_type:handle_event/3 matches on the full resource name, so a wrong key delivers nothing. That key is generated with rabbit_guid:gen/0, whose own docstring states it "should be used when performance is a priority and predictability is not an issue. Otherwise use gen_secure/0."
gen/0 advances a per-process chain by a reversible transform. A party that observes reply-to keys from a given channel or session process can therefore derive keys that the same process generates later, including keys it uses for conversations with other peers.
Note on tooling: this report was prepared with AI assistance (Claude Code). The analysis and the proposed fix were reviewed by the submitter before filing.
Why this is reachable in practice
The reply-to key is not secret from the peer a client addresses — that peer is told the address so it can reply. Predictability matters because it lets that peer derive keys used with different peers.
Two properties make this more than theoretical:
- A client can allocate multiple keys on one channel.
basic.cancelresetsdirect_reply = none(rabbit_channel.erl:1391), so cancel-and-re-consume yields a fresh key from the same process and the same chain. Some clients do this per request as normal behaviour. - **The chain's other consumer is often attacker-observab…
Source: GitHub Repository Security Advisories (Game のスタック) GitHub Advisory OSV
References
- GITHUB_REPO_ADVISORY rabbitmq/rabbitmq-server