WaratekVRT Sign in

CVE-2022-41678 ActiveMQ

Affected softwareActiveMQ
Severity8.8 High CVSS 3.1
Fixed in5.16.6, 5.17.4
WeaknessImproper authentication (CWE-287)
Published28 Nov 2023
Updated17 Jun 2026

Description

Once an user is authenticated on Jolokia, he can potentially trigger arbitrary code execution.  In details, in ActiveMQ configurations, jetty allows org.jolokia.http.AgentServlet to handler request to /api/jolokia org.jolokia.http.HttpRequestHandler#handlePostRequest is able to create JmxRequest through JSONObject. And calls to org.jolokia.http.HttpRequestHandler#executeRequest. Into deeper calling stacks, org.jolokia.handler.ExecHandler#doHandleRequest can be invoked through refection. This could lead to RCE through via various mbeans. One example is unrestricted deserialization in jdk.management.jfr.FlightRecorderMXBeanImpl which exists on Java version above 11. 1 Call newRecording. 2 Call setConfiguration. And a webshell data hides in it. 3 Call startRecording. 4 Call copyTo method. The webshell will be written to a .jsp file. The mitigation is to restrict (by default) the actions authorized on Jolokia, or disable Jolokia. A more restrictive Jolokia configuration has been defined in default ActiveMQ distribution. We encourage users to upgrade to ActiveMQ distributions version including updated Jolokia configuration: 5.16.6, 5.17.4, 5.18.0, 6.0.0.

CWE-502 · Deserialization of untrusted data

Exploitation status

Working exploit published

A reviewed exploit catalogue lists ready-to-run exploit code for this CVE.

  • CISA KEV not listed
  • VulnCheck KEV not listed
  • CISA Vulnrichment no assessment published
  • Indexed PoC 4 indexed Published artifacts you can open, in GitHub PoC, Nuclei; first seen 2024-11-28.
  • EPSS 86% chance in 30 days A model's forecast, not a report of exploitation. Higher than 99.7% of all scored CVEs.

2 of these are GitHub repositories with fewer than 5 stars. They are listed for reference and don't count toward the exploitation status above.

IndexArtifactStarsFirst seen
GitHub PoC Apache ActiveMQ漏洞综合利用工具(CVE-2015-5254,CVE-2016-3088,CVE-2022-41678,CVE-2023-46604,CVE-2024-32114,CVE-2026-34197,CVE-2026-40466, CVE-2026-42588) 86 2026-04-20
GitHub PoC CVE-2022-41678 是 Apache ActiveMQ 中的一个远程代码执行漏洞。该漏洞允许攻击者通过 JMX (Java Management Extensions) 接口修改 Log4j 配置或 JFR (Java Flight Recorder) 配置,从而写入恶意的 JSP webshell 到服务器的 web 目录中,最终实现远程代码执行。 2 2025-10-14
GitHub PoC CVE-2022-41678: Dangerous MBeans Accessible via Jolokia API in Apache ActiveMQ 2 2024-11-28
Nuclei Apache ActiveMQ < 5.16.5/5.17.3 - Remote Code Execution

Waratek protection

Protected by Waratek

Waratek has a rule that blocks attacks on this vulnerability.

Decided by A vulnerability class already blocked by an ARMR security rule
Finding Protected by Waratek's ARMR deserialization security rule, which blocks this class of attack at the JVM level without a rule written for this CVE specifically. The CVE's weakness is CWE-502: Deserialization of Untrusted Data.

How to mitigate CVE-2022-41678

Upgrade ActiveMQ to a release that fixes it: 5.16.6 or 5.17.4. Until you can, Waratek RASP blocks exploitation with its deserialization and process rules. It runs inside the Java application, with no code changes.

Waratek RASP Runtime protection for Java applications

Affected software and releases

Maven packages

Affected and fixed versions, from OSV.dev
PackageIntroducedFixedLast affected
org.apache.activemq:apache-activemq 0 5.16.6 unbounded
org.apache.activemq:apache-activemq 5.17.0 5.17.4 unbounded

Products and versions

2 products, 4 version entries
SourceVendorProductSchemeAffected versions
nvd apache activemq generic < 5.16.6 · ≥ 5.17.0 and < 5.17.4
osv org.apache.activemq apache-activemq generic < 5.16.6 · ≥ 5.17.0 and < 5.17.4

References

URLTags
https://github.com/apache/activemq/pull/958 WEB
https://github.com/apache/activemq/commit/5c8d457d9 WEB
https://github.com/apache/activemq/commit/6120169e563b55323352431dfe9ac67a8b4de6c2 WEB
https://github.com/apache/activemq/commit/bf65929fd WEB
https://github.com/apache/activemq/commit/d8ce1d9ff WEB
https://activemq.apache.org/security-advisories.data/CVE-2022-41678-announcement.txt WEB
https://github.com/apache/activemq PACKAGE
https://lists.apache.org/thread/7g17kwbtjl011mm4tr8bn1vnoq9wh4sl WEB
https://lists.debian.org/debian-lts-announce/2024/10/msg00027.html WEB
https://security.netapp.com/advisory/ntap-20240216-0004 WEB

Timeline

Published2023-11-28By the CVE Program.
NVD record modified2026-06-17NVD's own last-modified date for this record.