News
Java4Shell: Sonar Recommends a Temporary Workaround for SonarQube
Sonar's advisory says Java4Shell (CVE-2026-114938) may affect the SonarQube Server and Community Build runtime. Here is the temporary workaround.
Dr. Márton Tamás Kabai 3 min read
On 17 November 2026, Sonar published a security advisory about Java4Shell (CVE-2026-114938), which affects operators of SonarQube Server and SonarQube Community Build. The update of 20 November also covers the SonarQube MCP Server.
What is Java4Shell, and how does it affect SonarQube?
According to Sonar, the flaw lies in the Java runtime, not in Sonar’s own code. It affects the hardware-accelerated Base64 decoder in OpenJDK 17.0.6 and later versions (including Java 21 and 25). On x86-64 processors that support AVX-512 VBMI, it is reported to allow unauthenticated remote code execution. ARM-based machines are not affected. Sonar is currently not aware of any exploitation or related incident.
What does Sonar recommend?
- Server and Community Build: the supported Server versions (2026.5, 2026.1 LTA and 2025.4 LTA), the Community Build and older versions may be affected if they run on a vulnerable Java version and vulnerable hardware. The
-XX:-UseBASE64Intrinsicsflag must be set for the Web, Compute Engine and Search processes, without checking the processor beforehand. Sonar does not expect a noticeable performance impact. - Configuration for ZIP installations: in the
conf/sonar.propertiesfile, use thesonar.web.javaAdditionalOpts,sonar.ce.javaAdditionalOptsandsonar.search.javaAdditionalOptsproperties; SonarQube must be restarted for the change to take effect. A ZIP installation runs on its own Java, so it must also be updated when the JDK vendor releases a fixed build. - Configuration in Docker: use the
SONAR_WEB_JAVAADDITIONALOPTS,SONAR_CE_JAVAADDITIONALOPTSandSONAR_SEARCH_JAVAADDITIONALOPTSenvironment variables (with Docker Compose, in theenvironmentsection of the service); the container must be recreated. - Configuration on Kubernetes and with Helm: the same environment variables go into the
envsection of the values file (for thesonarqube-dcechart, underapplicationNodesandsearchNodes).jvmOpts,jvmCeOpts,SONAR_WEB_JAVAOPTSandSONAR_CE_JAVAOPTScannot be used, because the chart builds these itself. - General rules:
javaOptsis not suitable, because it overrides SonarQube’s default memory settings. The flag must be appended to existing values, separated by a space, rather than replacing them. Environment variables take precedence over thesonar.propertiesfile.JAVA_TOOL_OPTIONShas no effect on the Server processes, because SonarQube ignores it. - Scanners and CI agents: on x86-64 agents that analyze untrusted code, the same flag is recommended, for example through the
SONAR_SCANNER_JAVA_OPTSvariable. For SonarScanner for .NET,SONAR_SCANNER_OPTSorJAVA_TOOL_OPTIONScan be used, only with Java 17 or later. SettingJAVA_TOOL_OPTIONSat the agent level covers every JVM on the agent (including the build tool), but only on agents running Java 17 or later: Java 8 does not recognize the option and will not start with it. This setting does not replace the Server configuration. - MCP Server (20 November 2026): if you have enabled the MCP Server,
JAVA_TOOL_OPTIONS=-XX:-UseBASE64Intrinsicsmust be set separately in its standalone container (with Helm, in themcp.envsection of the values file), and the container must then be redeployed. The Server’s JVM settings are not applied automatically in the MCP container. IfJAVA_TOOL_OPTIONSalready contains options, the flag must be appended.
Verification and next steps
On Linux, you can check for the flag on the machine or inside the container with the command grep -la -- '-XX:-UseBASE64Intrinsics' /proc/[0-9]*/cmdline: it must appear for all three processes (Web, Compute Engine, Search). On any platform, you can also look at the Launch process[WEB_SERVER] and Launch process[COMPUTE_ENGINE] lines in logs/sonar.log or in the container log; the flag must appear in both JVM commands.
Sonar is monitoring Java vendor updates and will publish the confirmed fixed versions, the rebuilt Docker images and the upgrade guidance later. The flag can stay in place after the fix, but it can also be removed.
Action required: on affected installations, set the flag (for Data Center Edition, the Web and Compute Engine settings on the application nodes and the Search setting on the search nodes), verify it on the running processes, and follow Sonar’s advisory for the fixed versions.
Sources
Original announcement

Stevan Vanderwerf, SonarSourcer (Sonar)
Originally published on the Sonar Community forum on 18 November 2026: Security Advisory: Java4Shell workaround for SonarQube
About the editor

Dr. Kabai Márton Tamás, Owner and Managing Director, Szitár-Net Kft.
Source: Sonar Community
Edited by
Managing Director, Szitár-Net Kft.
Managing Director of Szitár-Net Kft. The company has worked with automated source code analysis for more than 10 years and, as the official SonarSource partner in Hungary, helps banks, public institutions and large enterprises adopt SonarQube. His talks cover code quality, cybersecurity compliance and secure AI-assisted development.
More news
News
SonarQube Server LTA Releases with the Java4Shell Fix Are Now Available
SonarQube Server 2026.5.6, 2026.1.9 and 2025.4.12 LTA now include the Java4Shell fix. Azure DevOps: the @7 and @3 tasks are removed on December 7.
Read on 4 min
News
Azure DevOps extensions: @7 and @3 tasks are removed on December 7
On December 7, SonarQube Server and Cloud Azure DevOps extensions get a new major version. The @7 and @3 tasks are removed, and pipelines using them fail.
Read on 3 min
News
SonarQube Server 2025.4.12 LTA: Java Runtime Fix for Java4Shell
SonarQube Server 2025.4.12 LTA is out with the Java runtime fix for Java4Shell, so the temporary server-side JVM workaround is no longer needed.
Read on 2 min