APM Java Agent Local Privilege Escalation issueGHSA-5xqm-hc45-f2g2
HIGHGHSA-5xqm-hc45-f2g2 is a high-severity (CVSS 7) Improper Privilege Management vulnerability in co.elastic.apm:apm-agent-parent. A fix is available for co.elastic.apm:apm-agent-parent — see the affected versions and patch details below.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
Where this sits among everything scored
Real-World Exposure
co.elastic.apm:apm-agent-parent☕co.elastic.apm:elastic-apm-agentReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Maven packages — download data is not available via public APIs for these ecosystems.
Description
A local privilege escalation issue was found with the APM Java agent, where a user on the system could attach a malicious plugin to an application running the APM Java agent. By using this vulnerability, an attacker could execute code at a potentially higher level of permissions than their user typically has access to.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| ☕Maven | co.elastic.apm:apm-agent-parent | ≥ 1.18.0&&< 1.27.1 | 1.27.1co.elastic.apm:apm-agent-parent:1.27.1 |
| ☕Maven | co.elastic.apm:elastic-apm-agent | ≥ 1.18.0&&< 1.27.1 | 1.27.1co.elastic.apm:elastic-apm-agent:1.27.1 |
Affected Products
apm java agentelasticDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for co.elastic.apm:apm-agent-parent, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update co.elastic.apm:apm-agent-parent to 1.27.1 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-5xqm-hc45-f2g2 is resolved across your whole dependency graph.
Workarounds
Close the privilege gap rather than the entry point: audit which accounts, roles and service identities can reach the affected operation, drop the component to the least privilege it actually needs, and review file and directory permissions created by earlier installs — a default left in place is what makes this reachable.
Frequently Asked Questions
Is GHSA-5xqm-hc45-f2g2 in your dependencies?
Find it across Maven, including transitive dependencies.