Blog · 2026-11-18 · Gardience Engineering · How we test

Java4Shell CVE-2026-114938: find and fix vulnerable Java on every server

Java4Shell (CVE-2026-114938) is a memory corruption bug in OpenJDK's Base64 decoder that allows remote code execution on Java 17, 21, 25, and 27 running on x86-64 CPUs with AVX-512 VBMI. Who is affected, the one-flag workaround, where the vendors are, and commands to find every Java runtime on Linux and Windows.

Find and fix CVEs across the fleet

Java4Shell (CVE-2026-114938) is a memory corruption bug in OpenJDK's Base64 decoder, made public on November 17,

  1. An attacker who can get an application to decode malformed Base64 can run code inside that Java process, and Red Hat notes that pre-authentication code execution has been demonstrated against widely deployed Java applications in their default settings (Red Hat bulletin RHSB-2026-018). Red Hat rates it Critical (9.8); OpenJDK scores it 8.1 (OpenJDK advisory).

The good news is that it only bites when three things are true at once. The bad news is that a lot of servers meet all three without anyone choosing to.

Who is affected?

#

According to Red Hat's bulletin, a server is exposed only when all of these hold:

  1. It runs Java 17.0.6 or later, including Java 21, 25, and 27. Java 8 and Java 11 do not contain the vulnerable code.
  2. The CPU is x86-64 with AVX-512 VBMI, which means Intel Ice Lake, Sapphire Rapids, Emerald Rapids, or Granite Rapids, or AMD Zen 4, Zen 5, or Zen 6. In the cloud that includes AWS C6i, M6i, R6i, C7i, M7i, and R7a, Google Cloud C3, C3D, C4, C4D, N4, N4D, M3, and M4, and Azure D-series v5 to v7. ARM64 servers are not known to be affected.
  3. The application decodes Base64 that an outsider controls. That is common: HTTP Basic sign-ins, SAML, CSRF tokens, and MIME email headers are all Base64, and many apps decode them before anyone has signed in.

Java picks the vulnerable fast path by itself when the CPU supports it, so no special setting is needed to be exposed. Keycloak is named in Red Hat's bulletin, and security researchers have reported working attacks on default installs of Jira, Jenkins, and Keycloak (The Hacker News). As of November 18 it is not on CISA's Known Exploited Vulnerabilities list.

Where are the vendors? (November 18)

#
SourceStatus
OpenJDKFixed in the November 17 releases; 17.0.21.0.3, 21.0.13.0.3, 25.0.5.0.3, 27.0.1.0.3, and earlier are affected (advisory)
Red Hat (RHEL 8, 9, and 10)Affected; Red Hat is expediting fixes, no updated packages yet (CVE page)
Ubuntuopenjdk-17, openjdk-21, and openjdk-25 vulnerable on every supported release, no fix yet; Java 8 and 11 not affected (Ubuntu CVE page)
DebianFixed in unstable only; bookworm and trixie still vulnerable (Debian tracker)
CISA KEVNot listed

Until your distribution ships the update, the workaround below is the fix.

The workaround: one flag

#

Start each affected Java process with this flag, which turns off only the hardware-accelerated Base64 code:

-XX:-UseBASE64Intrinsics

Red Hat calls this the preferred option. The other one, -XX:UseAVX=2, turns off all AVX-512 use, and a JVM on ARM64 will refuse to start with it, so only use it on x86-64.

For a service started by systemd, the cleanest way is a drop-in, since Java 9 and later read JDK_JAVA_OPTIONS from the environment:

sudo systemctl edit myapp.service
# add:
[Service]
Environment=JDK_JAVA_OPTIONS=-XX:-UseBASE64Intrinsics
sudo systemctl restart myapp.service

Apps with their own startup scripts usually take JAVA_OPTS or, for Keycloak, JAVA_OPTS_APPEND. Setting the variable is not proof. Check the running process:

jcmd <pid> VM.flags -all | grep UseBASE64Intrinsics
# want: bool UseBASE64Intrinsics = false

Remove the flag after you install the fixed Java, and restart again.

Find every Java runtime, on every server

#

The hard part is not the flag. It is knowing where Java is. Applications bundle their own Java, so java -version on the path tells you about one runtime out of several.

On Linux, this lists every Java binary on the local disks with its version, and says whether the CPU has AVX-512 VBMI:

for j in $(find / -xdev -type f -path '*/bin/java' 2>/dev/null); do
  echo "$j: $("$j" -version 2>&1 | head -1)"
done
grep -q avx512vbmi /proc/cpuinfo && echo "CPU: AVX-512 VBMI yes" || echo "CPU: AVX-512 VBMI no"

On Windows, in PowerShell:

Get-ChildItem C:\ -Recurse -Filter java.exe -ErrorAction SilentlyContinue |
  ForEach-Object { "$($_.FullName): $((& $_.FullName -version 2>&1 | Select-Object -First 1))" }
(Get-CimInstance Win32_Processor).Name

Compare the processor name with the list above. Anything at Java 17.0.6 or later on one of those CPUs, behind an app that faces the internet, goes first.

How Gardience handles it

#

One thing no package check sees is a Java runtime bundled inside an application or a container image, because the operating system did not install it. The find commands above catch the ones on disk; the application's vendor ships the fix for those.

Questions

#

Is Java 8 or Java 11 affected by Java4Shell?

#

No. Red Hat says OpenJDK 8 and OpenJDK 11 do not contain the vulnerable code path.

Are ARM servers affected?

#

ARM64 servers, including AWS Graviton, are not known to be affected. Only x86-64 CPUs with AVX-512 VBMI are.

Is there a patch for Java4Shell?

#

OpenJDK released fixed versions on November 17, 2026. Linux distributions are still building their packages; until yours ships, start each Java process with -XX:-UseBASE64Intrinsics.

Is Java4Shell being exploited?

#

As of November 18 it is not on CISA's Known Exploited Vulnerabilities list. Researchers have demonstrated pre-authentication code execution in a lab, so treat internet-facing Java apps as urgent.

Find every exposed machine in your first hour

The free license covers 10 Windows and Linux machines with no end date: CVE matching with CISA KEV and EPSS, and a one-click fix for only the exposed machines, with approval.

Free 10-machine licenseFree 90-day trial (25 machines)How CVE matching works

Salt is a trademark of its owner, Ansible is a trademark of Red Hat, Inc., and other names are trademarks of their owners. Gardience is independent and not affiliated with any of them.