Java4Shell: Calif discloses critical OpenJDK Base64 decoder bug

Java4Shell: Calif discloses critical OpenJDK Base64 decoder bug

Calif, a security firm, has disclosed Java4Shell (CVE-2026-114938), a memory-corruption vulnerability in OpenJDK's Base64 decoder. OpenJDK is the most popular Java runtime, and the authors score the bug 9.2 out of 10 (CRITICAL) under CVSS 4.0. They say a remote attacker with no credentials can overwrite heap memory, read it in the style of Heartbleed, and reach remote code execution. The post follows Calif's earlier PHP2Shell disclosure; the authors say they chose Java next because it is more familiar than PHP.

The bug is in the optimized decoding path. To decode Base64 faster, OpenJDK uses specialized AVX-512 VBMI instructions on supported x86-64 processors, and the flaw sits in the hand-rolled assembly code that handles the final few characters. The authors say Java eventually rejects the malformed input, but by then neighboring objects may already be corrupted. They stress the irony: memory safety is one of Java's biggest selling points, but much of Java itself is written in low-level languages such as C, C++ and assembly, where memory corruption is still a part of life.

Calif says its initial testing demonstrated remote code execution in widely deployed Java applications in their default configurations. Pre-auth RCE: Keycloak, Atlassian Jira, Atlassian Confluence, JFrog Artifactory, Jenkins and PingFederate. Post-auth RCE: Apache Kafka Broker, Apache Solr, Elasticsearch, Gerrit and Spinnaker. The authors say the lists are non-exhaustive. They also demonstrated RCE in sample applications built on Apache Struts and Spring Boot, and say ordinary features such as authentication and file uploads can expose the vulnerable decoder, so the impact may extend well beyond the products tested. A client-side exploit shared by samczsun means a Java program that opens a TLS connection to a malicious server can be compromised even if it exposes no service. A demo video accompanies the post.

Calif says it used AI to find and weaponize the bug, as it did with PHP2Shell. According to the authors, researcher Quang Luong took an hour to discover the vulnerability and two more hours to develop the first working exploit, and the total token cost was less than $200. In his own section, Luong says he had told Codex to audit the JIT compiler, intrinsics, widely accessible APIs and cryptography in OpenJDK. Most early results were useless, either unreachable or unrealistic to exploit, until Codex eventually brought a finding for memory corruption in the Base64 decoder. The authors add that there is no universal exploit: depending on how Base64 is used and how the application works, different steps may be required. Calif sped things up by building pipelines and strategies first, then directing AI agents to use them; most later exploit chains were built almost autonomously with AI. The source text is cut off partway through the technical write-up.

The second half of the post is an argument about code bloat. Java has grown over the years to serve many needs, and everyone inherits the complexity of features only some people use. The Base64 optimization helps applications that decode enormous amounts of data, but the code ships to everyone, so an optimization few applications needed became a serious security risk. Calif points to Squidbleed, an older cousin of Heartbleed it found earlier this year, hiding in the Squid proxy's FTP module since 1997, and says FTP is a dead protocol that should be removed. It proposes what it calls vibe-uncoding: using AI to identify the parts a system actually needs and remove everything else to reduce its attack surface. The authors concede that removing code is harder than it sounds, since an apparently unused feature may have hidden dependencies.

Key facts

  • Calif disclosed Java4Shell (CVE-2026-114938), a memory-corruption bug in OpenJDK's Base64 decoder, scored 9.2 out of 10 (CRITICAL) under CVSS 4.0.
  • Calif says it demonstrated pre-auth RCE in Keycloak, Atlassian Jira, Atlassian Confluence, JFrog Artifactory, Jenkins and PingFederate, and post-auth RCE in Apache Kafka Broker, Apache Solr, Elasticsearch, Gerrit and Spinnaker.
  • The bug is in hand-rolled assembly that uses AVX-512 VBMI instructions on supported x86-64 processors.
  • The authors say Quang Luong found the bug in an hour, built the first working exploit in two more hours, and the total token cost was under $200.
  • Calif proposes 'vibe-uncoding': using AI to find and remove code a system does not need, to shrink its attack surface.

Why it matters

Java is a base layer for a great deal of enterprise software. The authors describe it as the world's third most popular programming language, powering 90% of Fortune 500 companies, and OpenJDK as the most popular Java runtime. A critical bug in a routine function like Base64 decoding, which is used in authentication, file uploads and network messages, is notable because Java is sold on memory safety. The case also shows what AI-assisted offence looks like in practice: by the authors' account, a few hours of work and under $200 in tokens produced a working exploit.

Who it affects

Anyone running OpenJDK-based applications, according to the authors. Calif names Keycloak, Atlassian Jira, Atlassian Confluence, JFrog Artifactory, Jenkins and PingFederate (pre-auth), and Apache Kafka Broker, Apache Solr, Elasticsearch, Gerrit and Spinnaker (post-auth), and says the lists are not exhaustive. Apache Struts and Spring Boot sample applications were also exploited. Java programs that open a TLS connection to a malicious server are exposed to a client-side exploit even if they run no service.

How to use it

This is a vulnerability disclosure, not a tool. The visible text describes no mitigation or workaround beyond the general argument for removing unused code, and gives no patched OpenJDK versions. Teams can read the named product lists as a starting point for checking their own estate and should watch for vendor and OpenJDK advisories. The authors' broader suggestion is to use AI to find dead code and needless optimizations in large codebases and remove them.

How solid is it

This is a first-party disclosure from Calif, and every claim about severity, affected products and exploit results comes from the authors themselves. The CVSS 9.2 score is theirs, and the product list reflects their own testing. The source text is truncated in the middle of the exploitation section, so the full technical chain is not visible. The visible text gives no vendor responses, no confirmation that listed products are patched, and no evidence of exploitation in the wild.

Risks and caveats

The authors say there is no universal exploit; results depend on how Base64 is used in each application. The visible text does not say which OpenJDK versions are fixed or whether CPUs without AVX-512 VBMI are affected, other than saying the optimized instructions are used on supported x86-64 processors. The vibe-uncoding proposal is an opinion piece attached to the disclosure, and the authors themselves note that removing code is hard because apparently unused features can have hidden dependencies.

“What can we delete?”

— Calif, Java4Shell write-up, on the question security should ask instead of 'What can we build?'