CVE-2021-25646 Authenticated users can override system configurations in their requests which allows them to execute arbitrary code.
Authenticated users can bypass disabled JavaScript execution settings to run arbitrary code on the server.
- 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-25646?
CVE-2021-25646 is a high-severity code injection vulnerability in Apache Druid, published on 29 Jan 2021. Any signed-in user can exploit it over the network, with no action from the victim.
Official description
Apache Druid includes the ability to execute user-provided JavaScript code embedded in various types of requests. This functionality is intended for use in high-trust environments, and is disabled by default. However, in Druid 0.20.0 and earlier, it is possible for an authenticated user to send a specially-crafted request that forces Druid to run user-provided JavaScript code for that request, regardless of server configuration. This can be leveraged to execute code on the target machine with the privileges of the Druid server process.
Which versions are affected by CVE-2021-25646?
2 open source packages ship an affected version, including org.apache.druid:druid. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
org.apache.druid:druid Maven | All versions | 0.20.1 |
org.apache.druid:druid Maven | All versions | 0.20.1 |
Products include Apache Druid.
How do I fix CVE-2021-25646?
Upgrade org.apache.druid:druid to 0.20.1 or later.
Upgrade, and never evaluate templates, expressions or code built from user input. More about Code injection.
Is CVE-2021-25646 being exploited?
It is not confirmed as exploited in the wild, but public exploit code for CVE-2021-25646 exists.
Public exploit code: 1 Metasploit module, 1 Nuclei template and 13 proofs of concept on GitHub.
Other vulnerabilities in Apache Druid
- CVE-2026-23906 Apache Druid: Authentication Bypass via LDAP Anonymous Bind
- CVE-2025-59390 Apache Druid: Kerberos authenticaton chooses a cryptographically unsecure secret if not configured explicitly.
- CVE-2021-26919 Apache Druid Authenticated users can execute arbitrary code from malicious MySQL database systems.
- CVE-2024-45537 Apache Druid: Users can provide MySQL JDBC properties not on allow list
- CVE-2021-36749 Druid ingestion system Authenticated users can read data from other sources than intended
Sources
Also known as GHSA-wrqf-rrrw-w3mg.