
This post is a translation of the Spanish original.
Java4Shell: the flaw isn't in your code, it's in whichever CPU you get
The first thing I did when I read the Java4Shell advisory was look up which function was broken. Base64. Base64 decoding, something any Java application does dozens of times per second without anyone remembering it exists.
The second thing was to reread a condition that seemed the most interesting part of all: the flaw only triggers if the machine has a specific CPU.
What happened
On 17 November Oracle published its quarterly Java patch and OpenJDK its security advisory. Among the fixes is CVE-2026-114938, dubbed Java4Shell: a heap overflow in HotSpot's Base64 decoder. Not in java.util.Base64 as Java code, but in the "intrinsic" version, the one the JVM swaps for AVX-512 instructions to go faster on x86-64.
According to analyses published by Qualys, Equixly and others, crafted Base64 makes the JVM write a few bytes past the end of an array. It affects Java 17 from 17.0.6, Java 21 and Java 25, but only on processors with AVX-512 VBMI and with the intrinsic enabled. Standard Java 8 and 11 don't have that shortcut. Oracle scores it 8.1 in CVSS 3.1 and the researchers talk about 9.2 in CVSS 4.0.
The context makes it worse. The details leaked before the patch came out, and although there was no confirmed exploitation as of the advisory, the clock is already ticking. There's a temporary mitigation: start the JVM with -XX:-UseBASE64Intrinsics, which disables the accelerated decoder and falls back to the normal implementation.
What worries me from the systems side
Depending on hardware sounds like good news. "My servers don't have AVX-512, moving on." And that's exactly the reasoning I wouldn't follow.
On your own hypervisor you may know which CPU you have. In the cloud, not always. The same container image can land today on a host without those instructions and tomorrow on a newer one that does have them, because the provider renewed hardware or because autoscaling chose a different instance type. The vulnerability doesn't live in your code or your image: it appears or disappears depending on where it runs.
On top of that, Java hides in more places than you'd think. Jenkins, Keycloak, internal tools, the management panel of some appliance that ships its own bundled JRE. That last one worries me most, because you don't update it: you wait for the vendor to release a version.
The best argument on the other side is reasonable: if the attack needs attacker-controlled data to reach a Base64 decoder and the CPU to meet specific requirements, the real attack surface is smaller than Log4Shell's, and the name exaggerates. I half buy it. Being less universal doesn't change the fact that Base64 is in HTTP headers, tokens and request bodies, which is exactly what an exposed service receives.
What I'd do today
Inventory first, patch second, and the flag as a bridge wherever you can't patch right away. If an application can't be restarted this week, at least leave -XX:-UseBASE64Intrinsics in its configuration for the next start. You'll lose some decoding performance. I haven't measured it and don't know how much it is on real workloads, but I struggle to imagine a case where it's worth it against the risk.
What leaves me thinking is the other part: more and more performance comes from hardware-specific shortcuts that almost nobody audits. How many more flaws are waiting in instructions that only exist on whichever CPU you happen to get?
Sources
- OpenJDK Vulnerability Advisory: 2026/11/17
- Oracle Critical Security Patch Update Advisory - November 2026
- Qualys: How to Find, Mitigate, and Patch the Critical Java4Shell Flaw
- Equixly: CVE-2026-114938, pre-auth heap overflow in Java 17, 21, and 25
- The Hacker News: Critical Java4Shell Flaw Enables Pre-Auth RCE


