RabbitMQ Serverでの LDAP認証失敗時に未認証でログを大量出力される
Summary
RabbitMQ Serverでは、rabbitmq_auth_backend_ldapを有効にして user_dn_pattern に ${username} を含む設定のとき、未認証の攻撃者が失敗するAMQP PLAINログインを送るだけでブローカーのログを大量に出力させられます。認証回避やリモートでのコード実行ではなく、ログ、ディスク、メモリの消費によるサービス品質の低下が主な影響です。修正版はバージョン4.3.7、4.2.12、4.1.17、3.13.21で提供されています。該当する場合は修正版へのアップデートを検討してください。
AI summary
Produced by SecPulse using an external AI model; it may contain mistakes. Check the original description and references below before acting on it.
RabbitMQ Serverでは、rabbitmq_auth_backend_ldapを有効にして user_dn_pattern に ${username} を含む設定のとき、未認証の攻撃者が失敗するAMQP PLAINログインを送るだけでブローカーのログを大量に出力させられます。認証回避やリモートでのコード実行ではなく、ログ、ディスク、メモリの消費によるサービス品質の低下が主な影響です。修正版はバージョン4.3.7、4.2.12、4.1.17、3.13.21で提供されています。該当する場合は修正版へのアップデートを検討してください。
Affected packages
| Package | Affected → Fixed | |
|---|---|---|
| rabbitmqrabbitmq-server |
>= 4.3.0, < 4.3.7→ 4.3.7 |
4.3.7 |
| rabbitmqrabbitmq-server |
>= 4.2.0, < 4.2.12→ 4.2.12 |
4.2.12 |
| rabbitmqrabbitmq-server |
>= 4.1.0, < 4.1.17→ 4.1.17 |
4.1.17 |
| rabbitmqrabbitmq-server |
>= 3.13.0, < 3.13.21→ 3.13.21 |
3.13.21 |
Original description The description as published by the source.
Summary
An unauthenticated client can amplify RabbitMQ's broker logs by sending a failed AMQP PLAIN login when rabbitmq_auth_backend_ldap is enabled with a user_dn_pattern containing ${username}.
After OpenLDAP rejects the bind, the LDAP backend returns the constructed user DN as the format-string element of {refused, Format, Args}. RabbitMQ's core authentication path then passes that attacker-influenced DN to Erlang formatting functions. A short username such as ~10000n expands into 10,000 newlines at each of two refusal sinks.
This is not an authentication bypass, an LDAP protocol flaw, or remote code execution. The demonstrated impact is unauthenticated availability degradation through log, disk, formatting, and per-connection memory amplification.
Environment and affected versions
The end-to-end validation used:
- A RabbitMQ source build on Erlang 27.3.4.17
- An isolated AMQP listener
- The bundled
rabbitmq_auth_backend_ldapplugin - A real OpenLDAP service
user_dn_pattern = cn=${username},dc=dast,dc=local
The complete LDAP-to-format chain was separately confirmed in RabbitMQ tags v3.13.7, v4.0.9, v4.1.8, v4.2.9, and v4.3.6, and on current main. No fixed release was identified. These are verified affected snapshots; an exact first affected release was not established.
Workarounds
Disable the LDAP plugin and switch to another authN backend.
Root cause
In RabbitMQ 4.3.6, with_login/5 in `deps/rabbitmq_auth_backend_lda…
Source: GitHub Repository Security Advisories (Game のスタック) GitHub Advisory OSV
References
- GITHUB_REPO_ADVISORY rabbitmq/rabbitmq-server