CVE-2026-40466: CWE-20 Improper Input Validation in Apache Software Foundation Apache ActiveMQ Broker
Improper Input Validation, Improper Control of Generation of Code ('Code Injection') vulnerability in Apache ActiveMQ Broker, Apache ActiveMQ All, Apache ActiveMQ. An authenticated attacker may bypass the fix in CVE-2026-34197 by adding a connector using an HTTP Discovery transport via BrokerView.addNetworkConnector or BrokerView.addConnector through Jolokia if the activemq-http module is on the classpath. A malicious HTTP endpoint can return a VM transport through the HTTP URI which will bypass the validation added in CVE-2026-34197. The attacker can then use the VM transport's brokerConfig parameter to load a remote Spring XML application context using ResourceXmlApplicationContext. Because Spring's ResourceXmlApplicationContext instantiates all singleton beans before the BrokerService validates the configuration, arbitrary code execution occurs on the broker's JVM through bean factory methods such as Runtime.exec(). This issue affects Apache ActiveMQ Broker: before 5.19.6, from 6.0.0 before 6.2.5; Apache ActiveMQ All: before 5.19.6, from 6.0.0 before 6.2.5; Apache ActiveMQ: before 5.19.6, from 6.0.0 before 6.2.5. Users are recommended to upgrade to version 5.19.6 or 6.2.5, which fixes the issue.
AI Analysis
Technical Summary
This vulnerability involves improper input validation and control of code generation in Apache ActiveMQ Broker. An authenticated attacker can add a connector using HTTP Discovery transport via BrokerView.addNetworkConnector or BrokerView.addConnector through Jolokia if the activemq-http module is on the classpath. A malicious HTTP endpoint can return a VM transport through the HTTP URI, bypassing the validation introduced in CVE-2026-34197. The attacker leverages the VM transport's brokerConfig parameter to load a remote Spring XML application context using ResourceXmlApplicationContext. Since Spring instantiates all singleton beans before BrokerService validates the configuration, arbitrary code execution occurs on the broker JVM via bean factory methods such as Runtime.exec(). This affects Apache ActiveMQ Broker versions before 5.19.6 and from 6.0.0 before 6.2.5.
Potential Impact
Successful exploitation allows an authenticated attacker to execute arbitrary code on the Apache ActiveMQ Broker's JVM, potentially leading to full compromise of the broker service. The vulnerability impacts confidentiality, integrity, and availability, as indicated by the CVSS vector (C:H/I:H/A:H). There are no known exploits in the wild at this time.
Mitigation Recommendations
A fix is available by upgrading Apache ActiveMQ Broker to version 5.19.6 or 6.2.5, which addresses this vulnerability. Users should apply these updates promptly to remediate the issue. No alternative mitigations or temporary fixes are documented. Patch status is confirmed by the vendor advisory recommending these versions.
CVE-2026-40466: CWE-20 Improper Input Validation in Apache Software Foundation Apache ActiveMQ Broker
Description
Improper Input Validation, Improper Control of Generation of Code ('Code Injection') vulnerability in Apache ActiveMQ Broker, Apache ActiveMQ All, Apache ActiveMQ. An authenticated attacker may bypass the fix in CVE-2026-34197 by adding a connector using an HTTP Discovery transport via BrokerView.addNetworkConnector or BrokerView.addConnector through Jolokia if the activemq-http module is on the classpath. A malicious HTTP endpoint can return a VM transport through the HTTP URI which will bypass the validation added in CVE-2026-34197. The attacker can then use the VM transport's brokerConfig parameter to load a remote Spring XML application context using ResourceXmlApplicationContext. Because Spring's ResourceXmlApplicationContext instantiates all singleton beans before the BrokerService validates the configuration, arbitrary code execution occurs on the broker's JVM through bean factory methods such as Runtime.exec(). This issue affects Apache ActiveMQ Broker: before 5.19.6, from 6.0.0 before 6.2.5; Apache ActiveMQ All: before 5.19.6, from 6.0.0 before 6.2.5; Apache ActiveMQ: before 5.19.6, from 6.0.0 before 6.2.5. Users are recommended to upgrade to version 5.19.6 or 6.2.5, which fixes the issue.
CVSS v3.1
Score 8.8high
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
This vulnerability involves improper input validation and control of code generation in Apache ActiveMQ Broker. An authenticated attacker can add a connector using HTTP Discovery transport via BrokerView.addNetworkConnector or BrokerView.addConnector through Jolokia if the activemq-http module is on the classpath. A malicious HTTP endpoint can return a VM transport through the HTTP URI, bypassing the validation introduced in CVE-2026-34197. The attacker leverages the VM transport's brokerConfig parameter to load a remote Spring XML application context using ResourceXmlApplicationContext. Since Spring instantiates all singleton beans before BrokerService validates the configuration, arbitrary code execution occurs on the broker JVM via bean factory methods such as Runtime.exec(). This affects Apache ActiveMQ Broker versions before 5.19.6 and from 6.0.0 before 6.2.5.
Potential Impact
Successful exploitation allows an authenticated attacker to execute arbitrary code on the Apache ActiveMQ Broker's JVM, potentially leading to full compromise of the broker service. The vulnerability impacts confidentiality, integrity, and availability, as indicated by the CVSS vector (C:H/I:H/A:H). There are no known exploits in the wild at this time.
Mitigation Recommendations
A fix is available by upgrading Apache ActiveMQ Broker to version 5.19.6 or 6.2.5, which addresses this vulnerability. Users should apply these updates promptly to remediate the issue. No alternative mitigations or temporary fixes are documented. Patch status is confirmed by the vendor advisory recommending these versions.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- apache
- Date Reserved
- 2026-04-13T13:38:42.111Z
- Cvss Version
- null
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 69eb479387115cfb681fd00b
Added to database: 4/24/2026, 10:36:03 AM
Last enriched: 5/1/2026, 8:31:43 PM
Last updated: 6/8/2026, 4:52:58 AM
Views: 2487
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.