CVE-2026-59408
Patch Available.
This Vulnerability has been fixed in the Never-Ending Support (NES) version offered by HeroDevs.
Overview
Spring Boot is an opinionated framework built on the Spring Framework for creating stand-alone, production-ready Java applications with minimal configuration. Its Maven plugin, spring-boot-maven-plugin, packages, runs and manages Spring Boot applications during a Maven build, including starting and stopping them around integration tests.
An incorrectly configured access control vulnerability (CVE-2026-59408) has been identified in the start goal of the Spring Boot Maven plugin, which allows attackers on an adjacent network who can reach the build machine to connect to the application under test through JMX without authentication. Through that unauthenticated JMX connection, an attacker can invoke management operations on the running application, which can lead to remote code execution.
Per OWASP: Access control enforces policy such that users cannot act outside of their intended permissions. Failures typically lead to unauthorized information disclosure, modification, or destruction of all data or performing a business function outside the user's limits.
This issue affects multiple versions of Spring Boot.
Details
Module Info
- Product: Spring Boot
- Affected packages: org.springframework.boot:spring-boot-maven-plugin
- Affected versions: <=2.7.35, >=3.0.0 <=3.4.18, >=3.5.0 <=3.5.17, >=4.0.0 <=4.0.9, >=4.1.0 <=4.1.2
- GitHub repository: https://github.com/spring-projects/spring-boot
- Published packages: https://central.sonatype.com/artifact/org.springframework.boot/spring-boot-maven-plugin
- Package manager: Maven
- Fixed in:
- OSS Spring Boot 4.0.10, 4.1.3
- NES for Spring Boot
Vulnerability Info
This Medium-severity vulnerability is found in the org.springframework.boot:spring-boot-maven-plugin package in multiple versions of Spring Boot. The plugin's start goal (StartMojo) forks the application under test in a separate JVM and enables the JDK's remote JMX agent so that the build can later wait for the application to become ready and stop it through the SpringApplicationAdminMXBean. The JVM arguments it adds turn authentication off:
@Override
protected RunArguments resolveJvmArguments() {
RunArguments jvmArguments = super.resolveJvmArguments();
List<String> remoteJmxArguments = new ArrayList<>();
remoteJmxArguments.add("-Dcom.sun.management.jmxremote");
remoteJmxArguments.add("-Dcom.sun.management.jmxremote.port=" + this.jmxPort);
remoteJmxArguments.add("-Dcom.sun.management.jmxremote.authenticate=false");
remoteJmxArguments.add("-Dcom.sun.management.jmxremote.ssl=false");
remoteJmxArguments.add("-Djava.rmi.server.hostname=127.0.0.1");
jvmArguments.getArgs().addAll(remoteJmxArguments);
return jvmArguments;
}java.rmi.server.hostname only sets the address that the RMI stubs advertise to clients. It does not restrict where the JMX connector listens, and neither com.sun.management.jmxremote.host nor com.sun.management.jmxremote.local.only is set, so the JMX RMI registry on jmxPort (9001 by default) is bound to all network interfaces of the build machine. With authenticate=false and ssl=false, the JMX agent accepts any client without credentials. The stop goal and the readiness check connect the same way, passing no credentials at all:
static JMXConnector connect(int port) throws IOException {
String url = "service:jmx:rmi:///jndi/rmi://127.0.0.1:" + port + "/jmxrmi";
JMXServiceURL serviceUrl = new JMXServiceURL(url);
return JMXConnectorFactory.connect(serviceUrl, null);
}For as long as the application started by the start goal is running, typically for the duration of an integration-test phase on a developer workstation or CI agent, any host on an adjacent network that can reach the JMX port can open a JMX session to it. The attacker can then read and modify MBean attributes, invoke MBean operations such as shutting the application down, and use the JMX management interface to run code inside the application's JVM.
Mitigation
Only recent versions of Spring Boot receive community support. Older lines are End-of-Life and will not receive public updates to address this issue.
Users of the affected components should apply one of the following mitigations:
- Upgrade to a currently supported version of Spring Boot.
- Leverage a commercial support partner like HeroDevs for post-EOL security support.