On 17 November 2026, Oracle fixed CVE-2026-114938 in Java SE, and the researchers who reported it, Calif, published the details the same day under the name Java4Shell. It's a memory-corruption bug in the fast, hardware-accelerated Base64 decoder that ships in every modern OpenJDK build, and Base64 is exactly the kind of data a server decodes before it knows who you are.
Oracle scores it 8.1 (CVSS 3.1) and calls the attack hard to pull off; under CVSS 4.0 it's 9.2. As of 19 November 2026 there was no confirmed successful attack and it was not in CISA's KEV catalog. Calif demonstrated pre-authentication code execution on six well-known products in their lab, though, and failed attempts simply crash the JVM, which a patient attacker can retry. This post explains the bug, who is actually exposed, the fixed builds, and the one-flag workaround.
How Base64 decoding works
Base64 turns every 4 characters into 3 bytes. TWFu decodes to the three bytes Man. When the data doesn't fill the
last group, it's padded with =: TWE= decodes to 2 bytes (Ma), TQ== to 1 byte (M). So the decoded length is:
output bytes = (characters / 4) * 3 - padding
Java's java.util.Base64 decoder is pure Java, but HotSpot replaces hot library methods with hand-written assembly
("intrinsics"). On x86-64 CPUs with AVX-512, the decoder intrinsic processes 64 characters per step. That fast path is
the one with the bug.
What happened: timeline
| Date | Event |
|---|---|
| Jan 2023 | OpenJDK 17.0.6 ships the AVX-512 Base64 decoder, backported from newer Java (first affected Java 17 build) |
| 9 Sep 2026 | An input that crashes the decoder is posted in a public OpenJDK pull request, later closed without merging |
| 17 Nov 2026 | Oracle's Critical Security Patch Update fixes it; Calif publishes its write-up and a bounded trigger |
| 18 Nov 2026 | Corretto, Azul Zulu and Temurin have fixed builds; Red Hat's fix still pending (per Tenable) |
Oracle credits Albert Yang and Quang Luong of Calif.io. Calif's write-up credits Quang Luong for the research and exploits and Jenish Rakholiya for exploit improvements.
The technical root cause
When the input doesn't end on a 64-character boundary, the intrinsic handles the last, partial piece separately. It works
out how many bytes to store with the formula above and turns that number into a store mask, a 64-bit value whose low n
bits say which bytes of the vector to write (built with the BZHI instruction, used by an evmovdqub masked store).
Now feed it 64 ordinary characters followed by a single = (Calif's trigger: "A".repeat(64) + "=", or 128 As on
Java 17). The last piece is one character:
(1 / 4) * 3 - 1 = 0 * 3 - 1 = -1
Nothing checked that the result was non-negative. In a 64-bit register, -1 is all ones, so the mask says write all 64 bytes, and they land past the end of an output buffer that was sized for the real data. Calif's bounded trigger shows 62 bytes (offsets 50-111) of a 4,096-byte array overwritten, even though Java then rejects the input as invalid.
That's an integer underflow leading to an out-of-bounds write, the same family of bug as the GitLab regex flaw. The fix is the missing check: if the computed length is negative, don't use the fast path.
Two conditions narrow who's exposed:
- The CPU. The intrinsic exists only on x86-64 with AVX-512 F, BW and VBMI plus BMI2: Intel Ice Lake or newer and AMD Zen 4 or newer, which covers many recent cloud instances. ARM64 servers (Graviton, Ampere, Apple silicon) don't have it.
- Warm-up. HotSpot only switches to the intrinsic once the decoder is hot (compiled by C2). On a busy server that takes seconds; an attacker can also warm it up by sending ordinary requests first.
What an attacker can do
Base64 travels in exactly the places a server reads before authentication:
Authorization: Basic ...headers (username and password, Base64-encoded)- JWTs (each part is Base64url)
- SAML responses in single sign-on
- uploads and message formats that embed Base64
Calif reports pre-auth remote code execution in their lab against Keycloak, Atlassian Jira, Atlassian Confluence, JFrog Artifactory, Jenkins and PingFederate, and post-auth RCE against Apache Kafka, Apache Solr, Elasticsearch, Gerrit and Spinnaker.
Proven vs claimed, as of 19 November 2026:
| Claim | Status |
|---|---|
| Heap memory corruption | Proven: Calif's public bounded trigger; other labs reproduced the crash |
| Pre-auth RCE on the six products | Demonstrated in the finders' lab; no full public exploit |
| Reliability | Low and per-target: each needs its own heap layout and timing; failed attempts crash the JVM |
| In the wild | Tenable cites GreyNoise seeing exploitation attempts, none confirmed successful; Canada's Cyber Centre was not aware of attacks; not in CISA KEV |
Our view: treat it as critical for anything internet-facing. A crash is a free retry, and Java sits behind a lot of login pages.
Who is affected
| Java line | Affected | Fixed (Oracle, Eclipse Temurin) |
|---|---|---|
| Java 17 | 17.0.6 and later | 17.0.21.1 |
| Java 21 | all builds before the fix | 21.0.13.1 |
| Java 25 | all builds before the fix | 25.0.5.1 |
| Java 27 | all builds before the fix | 27.0.1.1 |
| Java 8, 11 | not affected (no intrinsic), except Oracle's Java 8 Performance Pack 8u511b33-perf | n/a |
Oracle's advisory also lists GraalVM for JDK 17 and 21 and GraalVM Enterprise Edition 21.3. Other distributions use their own build numbers: Amazon Corretto and Azul Zulu released fixes; Red Hat had not as of 18 November 2026; the Microsoft Build of OpenJDK was listed as vulnerable without a fix date. Check your vendor's advisory.
A realistic scenario (hypothetical): Keycloak runs in a container on a modern cloud VM. The host OS gets patched monthly, but the image bundles its own Java 21, which only changes when someone rebuilds the image. The login page decodes Base64 from anyone on the internet. That's exposed until the image is rebuilt or the flag is set.
The CVE
| CVE | What | CVSS | KEV |
|---|---|---|---|
| CVE-2026-114938 | Out-of-bounds write in HotSpot's AVX-512 Base64 decoder (Oracle component: Compiler) | 8.1 (Oracle, CVSS 3.1, AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H); 9.2 (CVSS 4.0) | Not listed (19 Nov 2026) |
How to check if you're exposed
You're exposed only if all three are true: an affected version, an AVX-512 CPU, and no workaround flag.
1. The Java version actually running (not just what's on your PATH):
java -version
jcmd <pid> VM.version # a running service
readlink -f /proc/<pid>/exe # which java binary it really uses
2. The CPU (Linux). All four flags must be present:
grep -m1 '^flags' /proc/cpuinfo | tr ' ' '\n' | grep -E '^(avx512f|avx512bw|avx512vbmi|bmi2)$'
3. The flags the JVM runs with:
jcmd <pid> VM.flags -all | grep -E 'UseAVX|UseBASE64Intrinsics'
Or let the lab's checker combine all three (with no arguments it reads the local machine):
$ python3 check/check_java.py --version 21.0.4 --cpu x86-avx512 --flags=
EXPOSED Java 21.0.4 below 21.0.13.1, AVX-512 CPU, no workaround flag
$ python3 check/check_java.py --version 21.0.4 --cpu x86-avx512 --flags=-XX:-UseBASE64Intrinsics
NOT EXPOSED Base64 intrinsic switched off (-XX:-UseBASE64Intrinsics)
$ python3 check/check_java.py --version 21.0.4 --machine aarch64 --cpu none
NOT EXPOSED aarch64 CPU: the vulnerable decoder is x86-64 only
4. The Javas you don't see. Products and images often bundle their own runtime. Every JDK/JRE has a release file:
python3 check/check_java.py --scan /opt # lists each bundled runtime and its status
docker run --rm --entrypoint java <image> -version
5. Hunt. Failed attempts tend to crash the JVM. Look for new hs_err_pid*.log files on internet-facing Java services,
and at your web logs around those times for long Base64 values ending in = (Basic auth headers, JWTs, SAML):
python3 check/hunt_crashes.py /opt/atlassian /var/lib/jenkins
If you can't patch yet
Switch the vulnerable code off with a JVM option, then restart the service:
-XX:-UseBASE64Intrinsics # disables only the accelerated Base64 code; small cost on Base64-heavy work
-XX:UseAVX=2 # disables AVX-512 entirely; broader performance cost (x86-64 only)
Put it where the service reads its JVM options: JAVA_TOOL_OPTIONS, Tomcat's setenv.sh (also used by Jira and
Confluence), JAVA_OPTS in the systemd unit or container environment. Then confirm it's on:
java -XX:+PrintFlagsFinal -version | grep -E 'UseAVX|UseBASE64Intrinsics'
A WAF rule that blocks Basic auth headers ending in a lone = can help as a stopgap, but Base64 reaches Java from too many
places to rely on it.
Try it yourself: hands-on lab
The lab contains no exploit. It runs offline:
reproduce/base64_tail_model.pymodels the tail calculation in Python on a buffer with guard bytes: the buggy version overflows on"A" * 64 + "=", the fixed one rejects it, and normal input behaves the same in both. It's a simplified model of the logic, not the real assembly, so it reports 64 bytes where the real routine overwrote 62.check/check_java.pycombines version, CPU and flags into one verdict, and--scanlists bundled runtimes.check/hunt_crashes.pylists recent JVM crash logs and flags those that mention Base64 or stub routines.fix/README.mdlists fixed builds, the two flags, where to set them and how to verify.
$ python3 reproduce/base64_tail_model.py
buggy "A" x 64 + "=" tail length -1 -> mask all ones: 64 bytes past the buffer
fixed "A" x 64 + "=" tail length -1 -> REJECTED, no write
buggy "A" x 68 tail length 3 -> OK, stays inside the buffer
fixed "A" x 68 tail length 3 -> OK, stays inside the buffer
Key takeaways
- Patch login-facing Java first: single sign-on, Jira, Confluence, Jenkins, Artifactory.
- Your container's Java is not your host's Java. Rebuild images; scan for bundled runtimes.
- One flag buys time, and you can verify it in seconds.
- Fast paths need every check the slow path has. One missing negative check sat in production for almost three years.
Sources
- Calif, Java4Shell write-up and bounded trigger (17 Nov 2026)
- Oracle Critical Security Patch Update Advisory, November 2026
- NVD, CVE-2026-114938
- Datadog Security Labs, Java4Shell analysis
- Equixly, pre-auth heap overflow in Java 17, 21, 25 and 27
- Tenable, Java4Shell FAQ (vendor fix status)
- The Hacker News, Java4Shell