<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/java4shell-rce-in-openjdk-when-processing-base64-drof93tkm" -->

---
title: Java4Shell: RCE in OpenJDK when processing Base64
description: A critical memory-corruption vulnerability, CVE-2026-114938, hits OpenJDK's Base64 decoder and enables remote code execution. Dubbed Java4Shell, it scores 9.2...
canonical: https://daily.dev/posts/java4shell-rce-in-openjdk-when-processing-base64-drof93tkm
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Java4Shell: RCE in OpenJDK when processing Base64 | daily.dev
og:description: A critical memory-corruption vulnerability, CVE-2026-114938, hits OpenJDK's Base64 decoder and enables remote code execution. Dubbed Java4Shell, it scores 9.2...
og:url: https://daily.dev/posts/java4shell-rce-in-openjdk-when-processing-base64-drof93tkm
og:image: https://api.daily.dev/og/posts/dRof93TKm.png
og:image:alt: Java4Shell: RCE in OpenJDK when processing Base64
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Java4Shell: RCE in OpenJDK when processing Base64

**[Hacker News](https://daily.dev/sources/hn)** · 16 min read · 1 upvotes · 0 comments

## Summary

A critical memory-corruption vulnerability, CVE-2026-114938, hits OpenJDK's Base64 decoder and enables remote code execution. Dubbed Java4Shell, it scores 9.2 out of 10 (CRITICAL) under CVSS 4.0 and affects OpenJDK 17.0.6 and newer, plus derivatives like Corretto, Temurin, Zulu, and Oracle Java SE. A malformed input of 64 'A' characters followed by '=' triggers an out-of-bounds write in the AVX-512 VBMI-optimized decoding routine, requiring an x86-64 CPU with AVX-512 VBMI. Pre-auth RCE was demonstrated in Keycloak, Jira, Confluence, Jenkins, Artifactory, and PingFederate, with post-auth RCE in Kafka, Solr, Elasticsearch, Gerrit, and Spinnaker. Calif found the bug in an hour using AI assistance and built a working exploit in two more hours for under $200 in tokens.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://calif.io/java4shell>

## Questions this post answers

### What is CVE-2026-114938 and which Java versions does it affect?

CVE-2026-114938, called Java4Shell, is a memory-corruption vulnerability in OpenJDK's Base64 decoder that can lead to remote code execution. It affects OpenJDK 17.0.6 and newer, plus derivatives like Amazon Corretto, Eclipse Temurin, Azul Zulu, BellSoft Liberica, SAP SapMachine, Red Hat OpenJDK, and Oracle Java SE. It scores 9.2 out of 10 (CRITICAL) under CVSS 4.0.

_Teams tracking critical JVM CVEs before patching production servers can follow Java ecosystem security news on daily.dev._

### What input triggers the OpenJDK Base64 decoder out-of-bounds write bug?

On affected OpenJDK builds, 64 'A' characters followed by a single '=' triggers the bug, causing a 62-byte out-of-bounds write past a 50-byte allocated buffer. On older OpenJDK 17 builds, the trigger input is 128 'A' characters followed by '='. The flaw sits in the AVX-512 VBMI-optimized intrinsic used by the JIT compiler for fast Base64 decoding on x86-64 CPUs supporting that instruction set.

_Developers reproducing low-level JVM memory bugs can keep up with exploit writeups like this on daily.dev._

### Which real-world Java applications were shown vulnerable to the OpenJDK Base64 RCE bug?

Pre-authentication remote code execution was demonstrated in default configurations of Keycloak, Atlassian Jira, Atlassian Confluence, JFrog Artifactory, Jenkins, and PingFederate. Post-authentication RCE was shown in Apache Kafka Broker, Apache Solr, Elasticsearch, Gerrit, and Spinnaker. Apache Struts and Spring Boot sample applications were also compromised, and the affected hardware requires x86-64 CPUs with AVX-512 VBMI support.

_Teams running Keycloak, Jira, or Jenkins can track exposure to critical JVM vulnerabilities on daily.dev._

## Community take

How the wider developer community reacted, aggregated from 2 discussions and 126 comments across hackernews, lobsters (as of 2026-11-18).

**TL;DR:** Developers are impressed by the research quality but split on real-world severity: many argue the exploit's strict preconditions (x86-64 + AVX-512 VBMI, specific JDK versions, request-buffering config) make mass exploitation unlikely, while others warn that cloud CPU variance and transparent VM migration make patching urgent regardless.

**Sentiment:** 10% positive · 45% mixed · 45% skeptical

**The case for**

- Detailed detection scripts and reproducible PoC code were shared, helping teams quickly assess exposure.
- Some note AVX-512-capable hosts (modern Intel and AMD Zen4+ EPYC/Ryzen) are actually quite common, so the blast radius may be larger than it first seems.

**The pushback**

- Several argue the exploit's precondition stack (specific CPU features, JIT intrinsics, request buffering off) is an unusual and narrow combination, making it less severe than headline framing suggests.
- Cloud environments can silently migrate VMs or swap node hardware, so a host that's safe today could become vulnerable without notice.
- Comparisons to Log4Shell are seen as overblown 'claim inflation' that could desensitize responders to future, truly critical vulnerabilities.
- The write-up's AI-generated phrasing/tables were called confusing and hard to parse.
- Concerns that AI-assisted exploit discovery (as used for this CVE) could accelerate mass exploitation despite the exploit's current complexity and bespoke nature.

**By community**

- hackernews (mixed): Discussion ranges from practical detection/mitigation advice to broader debate over real-world risk, cloud CPU variability, and tangents into AI-assisted security research and societal instability.
- lobsters (skeptical): Commenters largely downplay the severity, calling it a 'nothingburger' compared to Log4Shell given the specific preconditions required, though some push back that the conditions aren't as rare as claimed.

**Hottest debate:** Whether the vulnerability's strict preconditions make it a low-risk 'nothingburger' or a serious threat given how common AVX-512 hardware and vulnerable configurations actually are in cloud environments.

**Open questions**

- Is Azul Platform Prime (Zing) actually affected given its closed-source, custom JIT?
- Are JRE 8 and other listed Oracle version numbers (e.g., 25.0.5.0.3) actually patched or still vulnerable?
- Could this vulnerability explain recent unrelated outages (banks, supermarket systems) that commenters speculated about?
- How much latent risk exists from transparent cloud VM/node migration moving workloads onto AVX-512 hardware after the fact?

**Highlights**

> From the section on performing heap grooming over the network ("Remote Heap Feng Shui"): > The current attack is sensitive to network conditions, like RTT and jitter. Low, stable round-trip times are preferred for a more reliable attack. In our controlled environment, we performed this attack over the internet through public IP addresses instead of just assuming perfect laboratory conditions. For the current attack path to achieve optimal stability and reliability in exploitation, Calif turned to physics and utilized money to solve the problem, rather than experimenting with TCP/IP stack configuration. In other words, Calif rented another VM in the same region as our target. And the "Limitations" section: > There is no universal payload. Each chain needs a decoder route, a live writer, a returned reader or another feedback path, a heap layout, and an application action. Every target needs a bespoke profile. The exploit is not a universal point-and-shoot. Based on the complexity and constraints, short-term mass-exploitation seems unlikely. It will take some time before there are reliable exploits, and they may require running on infra close to the target. But a long tail of unpatched java applications/services at high-value targets getting exploited, seems plausible to me.
> — [lucasluitjes on hackernews · 4 comments](https://news.ycombinator.com/item?id=50539499)

> Compared to log4shell this feels like a nothingburger from the guys who already took 2h of my time for a previous nothingburger. Not even a mention of minecraft, *the* reason for lingering custom java installations running on big machines 24/7 - and which log4shell famously was an attack against.
> — [proctrap on lobsters · 2 points](https://lobste.rs/s/g0bf9i/java4shell_write_once_rce_everywhere#c_iqug8t)

> Super impressive work by Calif as usual. The exploit conditions are very specific but there are still going to be a lot of hosts impacted. We at Semgrep published some free detection scripts here: https://github.com/semgrep/detection-scripts/tree/main/CVE-2... They look for these five conditions:   * HotSpot VM: any OpenJDK build, Oracle JDK, or GraalVM JDK. Only HotSpot generates the stub. OpenJ9 and GCJ are OK. Azul Prime (Zing), which replaces C2 with its own JIT, and any VM name not recognized as HotSpot are [?], never [!].   * x86-64 JVM on an x86-64 host.   * Version 17.0.6 or later, not at or above a version listed in FIXED_IN, and no newer than the newest releases checked (see below). Newer versions are [?]: they may carry the fix.   * The JVM reports avx512_vbmi and avx512bw, and UseAVX >= 3.   * Base64 intrinsics are on and C2/JVMCI can compile. These turn it off: -XX:-UseBASE64Intrinsics, -XX:DisableIntrinsic=_base64_decodeBlock, -Xint, -XX:TieredStopAtLevel below 4.
> — [ievans on hackernews · 3 comments](https://news.ycombinator.com/item?id=50538391)

> I think something that might help is a metric for the likelihood of mass exploitation. Afaik CVSS  only measures complexity and CIA impact. A non-exhaustive list of questions that would be helpful to ask about a vulnerability: * Does the exploit need to be tailored per application? * Does it require mulitiple consecutive requests to the same process? * Does it network latency hinder reliability of the exploit? * How common is the configuration? (I think the claim inflation was inevitable. Relying on the person/org who found the vulnerability to correctly assess it's seriousness is a flawed approach. Even if ignoring commercial incentives, in the excitement of finding a serious vulnerability in a popular piece of software, it's difficult for a researcher to be perfectly objective.)
> — [lucasluitjes on lobsters · 1 points](https://lobste.rs/s/g0bf9i/java4shell_write_once_rce_everywhere#c_queqoy)

> GLM 5.3 produced this after a bit of prodding. I started out with the C++ sources with a bug marker instead of the fix: https://github.com/openjdk/jdk/commit/5177a70b385c16f26ede19... There are only a bunch of commits that came in the latest merge of security fixes, and this one changed VBMI-related intrinsics code, so it's a good match for what was publicly disclosed at the time.     import java.util.Arrays;     import java.util.Base64;          public class Canary {         // static fields defeat escape analysis so dst/canary really live in the heap         static byte[] dst;         static byte[] canary;              public static void main(String[] args) {             // (input, expected decodedOutLength) pairs:             //   65 = "A"*64 + "="    -> fragment "="   (length 1, trailing pad)             //   66 = "A"*64 + "Q="   -> fragment "Q="  (length 2, trailing pad)             //   67 = "A"*64 + "QQ="  -> fragment "QQ=" (length 3, trailing pad)             //   68 = "A"*64 + "QQ==" -> fragment 4 bytes, well-formed control case             int[][] cases = { { 65, 50 }, { 66, 50 }, { 67, 50 }, { 68, 49 } };             byte[][] srcs = new byte[cases.length][];             for (int c = 0; c < cases.length; c++) {                 int len = cases[c][0];                 byte[] src = new byte[len];                 Arrays.fill(src, (byte) 'A');                 if (len == 65) { src[64] = '='; }                 if (len == 66) { src[64] = 'Q'; src[65] = '='; }                 if (len == 67) { src[64] = 'Q'; src[65] = 'Q'; src[66] = '='; }                 if (len == 68) { src[64] = 'Q'; src[65] = 'Q'; src[66] = '=';                     src[67] = '='; }                 srcs[c] = src;             }                  int iters = 300_000;             for (int iter = 0; iter < iters; iter++) {                 for (int c = 0; c < cases.length; c++) {                     byte[] src = srcs[c];                     int dstLen = cases[c][1];                     // fresh dst, then canary IMMEDIATELY after it in the TLAB                     dst = new byte[dstLen];                     canary = new byte[64];                     Arrays.fill(canary, (byte) 0x41);                     int before = canary.length;                     try {                         Base64.getDecoder().decode(src, dst);                     } catch (IllegalArgumentException e) {                         // expected for the malformed tails                     }                     if (canary.length != before || changed(canary)) {                         System.out.println(                             "*** ITERATION " + iter + ", input length " + src.length                             + ": DESTINATION BUFFER OVERRUN DETECTED");                         System.out.println(                             "canary.length = " + canary.length + " (expected 64)");                         System.out.println(                             "canary bytes  = " + toHex(canary, 48));                         return;                     }                 }                 if (iter % 50_000 == 0)                     System.out.println("iter " + iter + ": clean so far");             }             System.out.println(                 "no corruption detected in " + iters + " iterations");         }              static boolean changed(byte[] b) {             for (byte x : b) if (x != 0x41) return true;             return false;         }              static String toHex(byte[] b, int n) {             StringBuilder sb = new StringBuilder();             for (int i = 0; i < 64; i++)                 sb.append(String.format("%02x ", b[i]));             return sb.toString();         }     } I had to fix toHex() not to use b.length, otherwise it wouldn't print anything due to the negative array length field.     *** ITERATION 4076, input length 67: DESTINATION BUFFER OVERRUN DETECTED     canary.length = -1700370022 (expected 64)     canary bytes  = 69 a6 9a 69 a6 9a 69 a6 9a 69 a6 9a 69 a6 9a 69 a6 9a 69
> — [fweimer on hackernews](https://news.ycombinator.com/item?id=50539150)

**Source threads**

- [hackernews](https://news.ycombinator.com/item?id=50538240) · 395 points · 113 comments
- [lobsters](https://lobste.rs/s/g0bf9i/java4shell_write_once_rce_everywhere) · 24 points · 13 comments

## Similar posts on daily.dev

- [CVE-2026-48907: How the Joomla JCE Exploit Works and What to Do About It](https://daily.dev/posts/cve-2026-48907-how-the-joomla-jce-exploit-works-and-what-to-do-about-it-nnouuvxo2) · Latest Hacking News · 0 upvotes · 0 comments

---

Tags: [#security](https://daily.dev/tags/security), [#java](https://daily.dev/tags/java)

[View this post on daily.dev](https://daily.dev/posts/java4shell-rce-in-openjdk-when-processing-base64-drof93tkm)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Java4Shell: RCE in OpenJDK when processing Base64","url":"https://daily.dev/posts/java4shell-rce-in-openjdk-when-processing-base64-drof93tkm","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/java4shell-rce-in-openjdk-when-processing-base64-drof93tkm"},"datePublished":"2026-11-17T22:02:57.718Z","dateModified":"2026-11-18T00:36:20.928Z","description":"A critical memory-corruption vulnerability, CVE-2026-114938, hits OpenJDK's Base64 decoder and enables remote code execution. Dubbed Java4Shell, it scores 9.2...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/0102faba6ea440cdcc211cdc90943fd9?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/0102faba6ea440cdcc211cdc90943fd9?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Hacker News","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Hacker News","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/hn","url":"https://daily.dev/sources/hn"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/java4shell-rce-in-openjdk-when-processing-base64-drof93tkm","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"security,java","timeRequired":"PT16M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Hacker News","item":"https://daily.dev/sources/hn"},{"@type":"ListItem","position":3,"name":"Java4Shell: RCE in OpenJDK when processing Base64"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/java4shell-rce-in-openjdk-when-processing-base64-drof93tkm#faq","mainEntity":[{"@type":"Question","name":"What is CVE-2026-114938 and which Java versions does it affect?","acceptedAnswer":{"@type":"Answer","text":"CVE-2026-114938, called Java4Shell, is a memory-corruption vulnerability in OpenJDK's Base64 decoder that can lead to remote code execution. It affects OpenJDK 17.0.6 and newer, plus derivatives like Amazon Corretto, Eclipse Temurin, Azul Zulu, BellSoft Liberica, SAP SapMachine, Red Hat OpenJDK, and Oracle Java SE. It scores 9.2 out of 10 (CRITICAL) under CVSS 4.0. Teams tracking critical JVM CVEs before patching production servers can follow Java ecosystem security news on daily.dev."}},{"@type":"Question","name":"What input triggers the OpenJDK Base64 decoder out-of-bounds write bug?","acceptedAnswer":{"@type":"Answer","text":"On affected OpenJDK builds, 64 'A' characters followed by a single '=' triggers the bug, causing a 62-byte out-of-bounds write past a 50-byte allocated buffer. On older OpenJDK 17 builds, the trigger input is 128 'A' characters followed by '='. The flaw sits in the AVX-512 VBMI-optimized intrinsic used by the JIT compiler for fast Base64 decoding on x86-64 CPUs supporting that instruction set. Developers reproducing low-level JVM memory bugs can keep up with exploit writeups like this on daily.dev."}},{"@type":"Question","name":"Which real-world Java applications were shown vulnerable to the OpenJDK Base64 RCE bug?","acceptedAnswer":{"@type":"Answer","text":"Pre-authentication remote code execution was demonstrated in default configurations of Keycloak, Atlassian Jira, Atlassian Confluence, JFrog Artifactory, Jenkins, and PingFederate. Post-authentication RCE was shown in Apache Kafka Broker, Apache Solr, Elasticsearch, Gerrit, and Spinnaker. Apache Struts and Spring Boot sample applications were also compromised, and the affected hardware requires x86-64 CPUs with AVX-512 VBMI support. Teams running Keycloak, Jira, or Jenkins can track exposure to critical JVM vulnerabilities on daily.dev."}}]}
```

