AI Helped a Security Engineer Exploit a Java Vulnerability in Days

AI Helped a Security Engineer Exploit a Java Vulnerability in Days

AI Helped a Security Engineer Exploit a Java Vulnerability in Days

A security engineer who had never worked deeply inside the Java Virtual Machine built a working exploit for a critical Java flaw in three to four days, with artificial intelligence doing much of the heavy lifting. The work, at the Sunnyvale cybersecurity startup Calif, turned a newly discovered vulnerability into a reliable demonstration of its impact in a fraction of the time it would once have taken.

The vulnerability itself, nicknamed Java4Shell and tracked as CVE-2026-114938, was found even faster. Calif researcher Quang Luong discovered it in about an hour with an AI model, for less than $200 in computing, then built the first working exploit in about two more hours. Oracle and OpenJDK released fixes the same day, November 17, 2026, and the flaw scores 9.2 out of 10 for severity.

The story is not really about one bug. It is about how quickly AI is changing the economics of security research: work that once took elite teams months can now be done by a small group in days, and defenders must patch at the same speed attackers move.

Key takeaways

  • Calif researcher Quang Luong found Java4Shell, CVE-2026-114938, in about an hour with AI help, for less than $200.
  • Security engineer Jenish Rakholiya then built a reliable exploit in three to four days, work he says would normally have taken several weeks to a month.
  • The bug sits in Java’s Base64 decoder and can let an attacker run code on a server without logging in, scoring 9.2 out of 10.
  • Oracle and OpenJDK released fixes on November 17, 2026, and CISA told organisations to patch immediately.
  • AI is speeding up both discovery and exploit building, which puts new pressure on patching speed.

At a glance: how AI turned a Java vulnerability into a working exploit in days.

Detail What happened
Vulnerability Java4Shell, CVE-2026-114938, a memory-corruption flaw in OpenJDK’s Base64 decoder
Severity 9.2 out of 10 on the CVSS 4.0 scale
Discovery Found in about an hour by Quang Luong at Calif, using AI, for under $200
Exploit work Jenish Rakholiya built a reliable exploit in three to four days with AI assistance
Affected versions OpenJDK 17.0.6 and later, across versions 17, 21, 25 and 27
Fixes Released November 17, 2026; first fixed releases 17.0.21.1, 21.0.13.1, 25.0.5.1 and 27.0.1.1

What Java4Shell is, in plain terms

Java is one of the most widely used programming platforms in the world. Calif says it powers 90 percent of Fortune 500 companies, and it runs inside banks, airlines, telecoms firms and national security systems. A serious flaw in Java itself has an enormous blast radius, because the same code ships inside thousands of products.

Java4Shell sits in the code that decodes Base64, a common way of turning binary data into plain text so it can travel over the internet. To decode it faster, Java uses special instructions on some Intel and AMD server chips. The flaw is in a small piece of hand-written, low-level code that does that fast decoding: a crafted input makes it write past the end of its memory, an error called memory corruption, which Java is designed to prevent.

With careful work, an attacker can use that overflow to read sensitive data from a server’s memory or run their own commands on it, known as remote code execution. Calif says it achieved this without logging in on six widely used business tools in their default settings, including Jenkins, Jira, Confluence and Keycloak, and on five more, among them Elasticsearch and Apache Kafka, after logging in. The flaw only works on x86-64 processors with AVX-512 VBMI support, including recent Intel Xeon and AMD Zen 4 chips, while ARM is not affected. Ten Java distributions are affected, including Amazon Corretto, Microsoft’s build of OpenJDK and Oracle Java SE.

How AI turned weeks of exploit work into days

A technician with a laptop working between rows of servers in a data centre
Java runs on the servers behind banks, airlines and government systems, so a flaw in the platform itself reaches far beyond any single application.

Finding a vulnerability is only half the job. To prove a flaw matters, researchers must turn it into a working exploit, and that second stage is usually the slower and harder part. That is where Jenish Rakholiya’s story begins. Rakholiya, a 31-year-old security engineer from Gujarat in India, had joined Calif about a month earlier. An IIT Roorkee graduate and former Apple security engineer, he is more comfortable with C and Python than with Java.

That gap mattered, because Java code runs inside the Java Virtual Machine, known as the JVM, a very complex piece of software. Rakholiya had studied different virtual machines, but he had little experience with the JVM’s internals. What helped him was artificial intelligence: as he put it, AI was very helpful in getting him up to speed quickly, and the models were good at explaining what might have gone wrong when an approach failed.

His method was a partnership rather than a handover. He drew on concepts from exploiting other virtual machines, thought about whether the JVM had similar functionality, and asked the language model to explore a particular approach. When an approach failed, he relied on the model to work out why. The first exploits the team had built were not very reliable, so Rakholiya picked the application to make the exploit more reliable, finishing in three to four days, work he says would ordinarily have taken several weeks to a month. AI did not replace his expertise; it let him apply it to a new area far faster than learning the JVM from scratch. That pattern will be familiar to anyone who has used AI pair programming tools in an unfamiliar codebase, though the stakes here are higher.

An hour, under $200, and a flaw hiding for years

The discovery stage was even faster. Quang Luong, another security engineer at Calif, found the vulnerability with the latest AI models from OpenAI, in about an hour, for less than $200 in tokens. The New York Times reported that the model was GPT-6 Cyber from OpenAI, a model the BBC says is not yet public. After the team set up the tools and strategy, most of the later attack chains for individual products were built almost autonomously with AI.

The numbers are the part that should make defenders sit up. Small teams using top AI models can now build in days or hours attacks that once took elite hackers months, and the whole Java discovery cost less than $200. A November 2026 study by Forescout Research’s Vedere Labs points the same way: its researchers found 99 vulnerabilities in 90 hours using publicly available AI tools, spending just $935, work they estimated would otherwise have taken nine months. About a month earlier, AI models helped uncover PHP2Shell, flaws in the PHP engine behind a large share of the world’s websites.

What it means for patching, and for attackers

The uncomfortable truth is that the same acceleration helps both sides. AI is helping ethical hackers discover vulnerabilities faster, but it is also helping threat actors do the same. The advantage goes to whichever side moves faster once a flaw is known.

The disclosure itself was handled carefully. Calif worked with government agencies in five allied countries and with large vendors before announcing the flaw, and it says it will keep its attack code for individual products private until more systems are patched. There is no single universal exploit: each application needs a tailored approach, and chief executive Thai Duong has said the bug was not easy to turn into an attack, which gives defenders more time.

Even so, Duong has warned that vulnerabilities have a very long tail, and he predicted the flaw could threaten systems that are not updated for the next five to ten years. That is the real risk: the fix exists, but Java is embedded in so many products, containers and appliances that finding every copy is a long job. CISA told organisations to patch immediately, and to look for copies of the runtime bundled inside other software. Slow patching sits near the top of the AI security mistakes security teams keep making.

A patching checklist for Java teams

If your organisation runs Java anywhere, the Java4Shell disclosure is a reason to act now rather than wait for the next maintenance window. Use this checklist to work through the response:

  • Find every copy of Java. Check servers, desktops, containers and appliances, including runtimes bundled inside other software.
  • Update to a fixed release. The first fixed releases are 17.0.21.1, 21.0.13.1, 25.0.5.1 and 27.0.1.1. Do not wait for the next scheduled release.
  • Restart Java processes after patching. A patched file does nothing until the running process is restarted.
  • Use the workarounds where patching is not yet possible. Calif and Datadog list startup settings that switch off the vulnerable code. Use them only as a stopgap.
  • Check whether the affected chips are in use. The flaw only affects x86-64 processors with AVX-512 VBMI support, so prioritise recent Intel Xeon and AMD Zen 4 systems.
  • Plan the response like an incident. Assign an owner, set a deadline and track patching to completion. Our guide to AI incident response explains how.

The broader lesson is about speed. When a flaw can be found in an hour and exploited in days, a patching process built around monthly or quarterly cycles is no longer fast enough. The organisations that come out of Java4Shell safely are the ones that already knew where their Java was running.

Frequently asked questions

What is Java4Shell?

Java4Shell is the nickname for CVE-2026-114938, a memory-corruption flaw in OpenJDK’s Base64 decoder. It can let an attacker run code on an affected server without logging in, and it scores 9.2 out of 10.

How did AI help find the Java vulnerability?

Calif researcher Quang Luong used an AI model to audit parts of OpenJDK and found the flaw in about an hour, for less than $200. AI was also used to build the first working exploit in about two more hours.

How long did the exploit work take?

Security engineer Jenish Rakholiya built a reliable exploit in three to four days, using AI to learn the Java Virtual Machine and diagnose failed approaches. He says the same work would ordinarily have taken several weeks to a month.

Which Java versions are affected?

OpenJDK 17.0.6 and later, across release families 17, 21, 25 and 27. Ten distributions are affected, including Amazon Corretto, Microsoft’s build of OpenJDK and Oracle Java SE. Only x86-64 processors with AVX-512 VBMI are affected; ARM is not.

Is there a fix for Java4Shell?

Yes. Oracle and OpenJDK released fixes on November 17, 2026: the first fixed releases are 17.0.21.1, 21.0.13.1, 25.0.5.1 and 27.0.1.1, and CISA has told organisations to patch immediately.

Has Java4Shell been used in real attacks?

As of publication, no confirmed exploitation in the wild has been reported. Calif is withholding its application-specific exploit code until more systems have patched.

The bottom line

The Java4Shell story compresses the new reality of cybersecurity into a single week. A critical flaw in one of the world’s most widely used platforms was found in an hour for less than $200, turned into a working exploit in about three hours, and made reliable in three to four days by an engineer who had never worked deeply inside the Java Virtual Machine. The human expertise still mattered: Rakholiya’s experience with other virtual machines, and Luong’s judgement about what to audit, pointed the AI in the right direction.

For defenders, the conclusion is not to fear AI but to match its pace. Patching cycles built for a world where exploits took months will not hold up when they take days. The organisations that treat Java4Shell as a deadline, find every copy of Java they run and patch it now, will be fine. As Thai Duong put it, the best hacker right now is the centaur hacker, part human and part AI, and the best defence is a team that works the same way.

on this page