CVE-2021-41571 Pulsar Admin API allows access to data from other tenants using getMessageById API
Authenticated users can read data from other tenants via the Admin API due to insufficient validation of ledger IDs against topic permissions.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2021-41571?
CVE-2021-41571 is a medium-severity missing authorization vulnerability in Apache Pulsar, published on 1 Feb 2022. Any signed-in user can exploit it over the network, with no action from the victim.
Official description
In Apache Pulsar it is possible to access data from BookKeeper that does not belong to the topics accessible by the authenticated user. The Admin API get-message-by-id requires the user to input a topic and a ledger id. The ledger id is a pointer to the data, and it is supposed to be a valid it for the topic. Authorisation controls are performed against the topic name and there is not proper validation the that ledger id is valid in the context of such ledger. So it may happen that the user is able to read from a ledger that contains data owned by another tenant. This issue affects Apache Pulsar Apache Pulsar version 2.8.0 and prior versions; Apache Pulsar version 2.7.3 and prior versions; Apache Pulsar version 2.6.4 and prior versions.
Weakness: CWE-863
Which versions are affected by CVE-2021-41571?
6 open source packages ship an affected version, including org.apache.pulsar:pulsar. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
org.apache.pulsar:pulsar Maven | All versions to 2.6.4 | None |
org.apache.pulsar:pulsar Maven | All versions to 2.6.4 | None |
org.apache.pulsar:pulsar Maven | From 2.7.0 | 2.7.4 |
org.apache.pulsar:pulsar Maven | From 2.7.0 | 2.7.4 |
org.apache.pulsar:pulsar Maven | From 2.8.0 | 2.8.1 |
org.apache.pulsar:pulsar Maven | From 2.8.0 | 2.8.1 |
Products include Apache Pulsar.
How do I fix CVE-2021-41571?
Upgrade org.apache.pulsar:pulsar to a fixed version for your release line: 2.7.4 or 2.8.1.
Upgrade, and check permissions on every request on the server, not only in the interface. More about Missing authorization.
Is CVE-2021-41571 being exploited?
There is no known exploitation of CVE-2021-41571 in the wild and no public exploit code.
Other vulnerabilities in Apache Pulsar
- CVE-2021-22160 Authentication with JWT allows use of “none”-algorithm
- CVE-2023-30429 Apache Pulsar: Incorrect Authorization for Function Worker when using mTLS Authentication through Pulsar Proxy
- CVE-2024-27135 Apache Pulsar: Improper Input Validation in Pulsar Function Worker allows Remote Code Execution
- CVE-2024-27894 Apache Pulsar: Pulsar Functions Worker Allows Unauthorized File Access and Unauthorized HTTP/HTTPS Proxying
- CVE-2024-27317 Apache Pulsar: Pulsar Functions Worker's Archive Extraction Vulnerability Allows Unauthorized File Modification
Sources
Also known as GHSA-3whx-qrj5-hh2h.