
Java4Shell: 65 Bytes of Base64, a 50-Byte Allocation, and 62 Bytes Written Past the End of It
- GoogleNEWGoogle: Gemini 4 Carbon2026-11-10$2.00 / $10.00 per 1M tokens · 89 tok/s
- AnthropicNEWAnthropic: Claude Fable 5.22026-11-09$8.00 / $40.00 per 1M tokens · 97 tok/s
- orcaNEWOrca: OrcaC2 1.02026-11-079 tok/s
- OrcaNEWOrcaCyber: GLM 5.3 Abliterated / Uncensored2026-11-04$3.00 / $5.00 per 1M tokens · 88 tok/s
- OrcaNEWOrcaCyber: Hy4 Abliterated / Uncensored2026-11-04$0.80 / $1.60 per 1M tokens · 134 tok/s
- OrcaNEWOrcaCyber: Kimi K3.1 Pro Abliterated / Uncensored2026-11-04$2.00 / $5.00 per 1M tokens · 87 tok/s
- OrcaOrcaCyber: MiniMax M3.1 Flash Abliterated / Uncensored2026-10-29$0.80 / $1.60 per 1M tokens · 121 tok/s
- OrcaOrcaCyber: GLM 5.3 Flash Abliterated / Uncensored2026-10-27$0.80 / $1.60 per 1M tokens · 68 tok/s
- OrcaOrcaCyber: Qwen3.8 Flash Next Abliterated / Uncensored2026-10-26$0.80 / $1.60 per 1M tokens · 90 tok/s
- OrcaOrcaCyber: MiMo V2.6 Flash Abliterated / Uncensored2026-10-26$0.80 / $1.60 per 1M tokens · 44 tok/s
- MoonshotMoonshotAI: Kimi K3.1 Pro2026-10-2447Intelligence
- OrcaOrcaCyber: DeepSeek V4.1 Flash Abliterated / Uncensored2026-10-23$0.80 / $1.60 per 1M tokens · 195 tok/s
- minimaxMiniMax: M3.1 Flash2026-10-1929Intelligence
- OrcaOrca: OrcaCyber Ultra 1.02026-10-17$5.00 / $10.00 per 1M tokens · 120 tok/s
- deepseekDeepSeek: DeepSeek V4.1 Flash 10172026-10-1733Intelligence
- DeepSeekDeepSeek: DeepSeek V4.1 Flash2026-10-1740Intelligence
- DeepSeekDeepSeek: DeepSeek V4.1 Flash 09102026-10-17$0.15 / $0.60 per 1M tokens · 187 tok/s
- OrcaOrca: OrcaCyber Zero 1.52026-10-10$3.00 / $7.50 per 1M tokens · 143 tok/s
- openaiOpenAI: GPT-6.1 Sol2026-09-2955Intelligence
- anthropicAnthropic: Claude Sonnet 5.52026-09-2855Intelligence
The input is 65 bytes long: 64 capital A's and a single equals sign. OpenJDK decodes it into a buffer it sizes at 50 bytes, and the HotSpot Base64 intrinsic then writes 64 bytes, starting at offset 48. Sixty-two of them land on the heap, outside the array they were meant for, in a language whose central promise is that this cannot happen to you. Calif published the chain on 17 November 2026 as Java4Shell, tracked as CVE-2026-114938, and OpenJDK and Oracle shipped fixes the same afternoon. The find is being reported as AI-assisted; the specific model named in coverage is GPT-6 Cyber, the security-tuned OpenAI model released on 5 November 2026. That attribution is the most interesting and least settled part of the story, and it is worth keeping separate from the bug, which is settled and serious.
What the intrinsic got wrong
Java is memory-safe at the language level and not at the level that mattered here. HotSpot accelerates Base64 with hand-written x86-64 assembly, because ordinary compiled Java is not fast enough for the one workload where decoding throughput is the bottleneck. The routine processes input in 256-byte blocks, falls back to 64-byte blocks, and for tails shorter than 64 bytes uses evmovdqub — the AVX-512 form of VMOVDQU8 — with a 64-bit write mask that decides which of the 64 bytes in the vector register actually reach memory.
That mask is built from the input and output lengths, then adjusted for Base64 padding. The write-up walks through the arithmetic: the output length is (input_length / 4) * 3, then decremented once for a trailing = and once more for a second one. For the padded tails =, ==, X=, X==, XY= and ===, the decoded length is zero, and the padding adjustment then subtracts from zero. The value underflows to -1 or -2. The mask calculation does not clamp it, so the mask becomes all-ones and all 64 bytes get written.
The buffer was sized honestly. Runtime allocation for a 65-byte input is (ceil(65 / 4) * 3) - 1, which is 50 bytes. The spill starts at offset 48 — the position where the final decoded bytes would have gone — so 62 bytes of neighbouring heap get overwritten. Bytes 48 through 63 of that spill are always 0x9a. Only the first two bytes carry attacker control, and only partially. The decoder still rejects the input and Java still throws IllegalArgumentException. The write happens before the rejection. On OpenJDK 17 the threshold to reach the affected code path is higher, so the published trigger there is 128 A's plus the equals sign.
A fixed 62-byte write of mostly constant data does not sound like a remote code execution primitive, and by itself it is not one. What Calif built is a chain:
• First, arrange the heap so the spill lands on the length field of an adjacent array. That array becomes a writer whose declared length is now much larger than its contents, which turns the fixed write into a bounded, chosen-value write.
• Second, corrupt the length of a second array whose data is copied back into the HTTP response. That array is a reader, and the heap contents it returns become the disclosure primitive. Calif calls the pre-code-execution stage of this JavaBleed: heap memory that may hold personally identifying data, private keys, session tokens, or other secrets.
• Third, repair the objects the linear write damaged so the JVM keeps running, use the disclosed originals to restore headers and neighbours, and escalate the bounded write into arbitrary writes that reach the Code Cache and the JVM's hooks.
• Fourth, make the application-specific change and verify it through a live request. The paper stops before that last step for individual products and says the weaponised chains stay private until users have had a chance to upgrade.
The grooming layer is the part that makes this remote rather than local. G1 divides the heap into fixed regions, HotSpot hands each thread a private allocation buffer, and the attacker cannot see any of it. Calif's answer is the old one — spray writer and reader pairs until the decoder output lands next to one — plus a trick specific to HTTP: send the request body up to the point where the critical allocation happens, wait for the TCP acknowledgement, then send the rest. Small packets are more stable than one large one, which gives both allocation control and timing control. The attack is sensitive to round-trip time and jitter; in their test environment they solved that by renting a VM in the same region as the target rather than tuning a TCP stack.
Serious, and narrower than the name suggests
Two constraints cut exposure down hard, and both are worth stating before anyone starts an incident bridge.
The first is version. Java4Shell affects OpenJDK 17.0.6 and later, and therefore every distribution built from it: Amazon Corretto, Eclipse Temurin, Microsoft Build of OpenJDK, Azul Zulu, BellSoft Liberica, SAP SapMachine, Red Hat OpenJDK, Oracle OpenJDK, Oracle Java SE and Oracle GraalVM for JDK. Oracle's list of affected Java SE builds is 8u511b33-perf, 17.0.21.0.3, 21.0.13.0.3, 25.0.5.0.3 and 27.0.1.0.3. Anything older than 17.0.6 on the OpenJDK line is outside the affected code path.
The second is silicon. The vulnerable routine is AVX-512 VBMI assembly, so it only exists on x86-64 chips that implement those instructions. ARM64 is not affected at all, which removes every Graviton, Ampere and Apple-silicon deployment from the population in one line. On the Intel side the list is Xeon Ice Lake, Sapphire Rapids, Emerald Rapids and Granite Rapids; on AMD it is EPYC and Ryzen from Zen 4 onward. Calif publishes the check:
grep -m1 '^flags' /proc/cpuinfo | tr ' ' '\n' | grep -E '^(avx512f|avx512bw|avx512vbmi|bmi2)$'
All four flags must appear. That is a real reduction in scope — but the affected chips are exactly the ones that filled cloud fleets between 2021 and 2025, so "requires Sapphire Rapids" is not the reassurance it sounds like. A Java service on Graviton is safe. The same service on a current-generation Intel instance is in scope, and so is the Jira, Confluence, Keycloak, Jenkins, Artifactory or PingFederate instance sitting behind it, because Calif demonstrated pre-authentication RCE in the default configuration of each.
The demonstrated impact list splits cleanly. Pre-authentication: Keycloak, Atlassian Jira, Atlassian Confluence, JFrog Artifactory, Jenkins and PingFederate. Post-authentication: Apache Kafka Broker, Apache Solr, Elasticsearch, Gerrit and Netflix Spinnaker. Sample Apache Struts and Spring Boot applications were also exploited. The lists are explicitly non-exhaustive, and one detail matters more than the product names: a vulnerable JVM does not have to expose a service of its own. Researcher samczsun shared a client-side chain with Calif in which a Java program that merely opens a TLS connection to a malicious server is compromised by the response.

Patch, and the two flags that buy time
OpenJDK published its advisory on 17 November 2026 and Oracle released its Critical Patch Update at 1:00pm PT the same day, with 11 new Java SE patches. Oracle credits Quang Luong of Calif.io and Albert Yang for CVE-2026-114938. The mainline OpenJDK fix is small — a four-line guard that routes a padded Base64 tail shorter than one complete block to the Java handler instead of the optimised routine. That is the shape of the bug in one sentence: an optimisation for applications that decode enormous volumes of data was shipped to every runtime, and it exposed applications that gained nothing from it.
Until the update is applied, two JVM flags turn the intrinsics off:
• -XX:-UseBASE64Intrinsics disables hardware-accelerated Base64 encoding and decoding. This is the safer of the two because it is architecture-independent.
• -XX:UseAVX=2 disables AVX-512. It only works on x86-64 — OpenJDK on ARM does not recognise the flag and will refuse to start, so a fleet that mixes architectures cannot apply it blanket.
Neither flag is a fix, and both cost throughput on exactly the workloads that made the intrinsic worth writing. The useful thing to note is that neither needs a redeploy of application code, which is the difference between a mitigation you can run tonight and one you cannot.
Coverage on 17 and 18 November was unusually broad for a runtime bug: the New York Times ran it under the headline "A.I. Helps Find Major Security Bug in Java, a Software Platform Vital to the Internet", the BBC and Politico both covered it, Germany's federal cyber security office issued an advisory, and CISA's guidance was reported as urging immediate patching while noting the flaw was not on its Known Exploited Vulnerabilities list. That last distinction is the one to hold onto. Broad coverage is not evidence of exploitation, and at the time of writing there is no public report of Java4Shell being used in the wild.
The model credit, and what it does and does not say
Here is where the story needs care, because the version circulating is cleaner than the record.
Calif's own write-up does not name GPT-6 Cyber. It says the areas to audit were chosen by a human and then handed over: "I told Codex to look at those areas like any serious security researcher in 2026." Codex is OpenAI's coding agent, and it can be pointed at different underlying models, so a researcher running Codex with GPT-6 Cyber selected would produce exactly that sentence. But the write-up never says which model was behind it, and it never states a cost or a token count. The numbers that have been repeated — roughly an hour to discovery, two hours to a working exploit, under $200 in tokens — come from reporting on the disclosure, not from Calif's paper.

The model name comes from the same place. Coverage published on 17 and 18 November attributes the discovery to GPT-6 Cyber specifically, and the New York Times' framing is the broader "AI helped". OpenAI has not, as of 18 November, published its own account of the finding. Its two most recent cyber posts — the 17 November NATO update and the 10 November Cogent partnership — do not mention Java. So the honest statement is: AI-assisted discovery is confirmed by the researcher's own write-up, the specific model is reported rather than documented, and the efficiency figures are second-hand.
That gap does not diminish the result. It changes what can be inferred from it. A one-hour discovery on a 30-year-old runtime is a claim about search cost, and the only party that can substantiate it is the party that has the billing records. Until one of them publishes them, the defensible version is that a small firm pointed an agent at a mature codebase and came back with a critical memory-corruption bug in a region — hand-written assembly inside the JIT — that code review and fuzzing have both struggled with for years.
The exploit-development half of the write-up is more interesting than the discovery half, and it is also more clearly human. Calif describes the agent getting stuck on heap-grooming primitives, and the fix being a heap tracer and visualiser the team wrote so the agent could see the heap state. That is a division of labour worth naming: the model widened the search, and people built the instrumentation that turned a finding into a chain.
Patch the Planet is the frame, not the filing
The Java4Shell disclosure is being described as part of Patch the Planet, OpenAI's Daybreak initiative to support open-source maintainers, run with Trail of Bits. The programme is real and Calif is a named partner in it — Patch the Planet's own description says OpenAI is "partnering with HackerOne and Calif who are helping us take our efforts further with vulnerability triage, coordinated disclosure, and additional focused vulnerability discovery efforts". So the coordination route is exactly the one the initiative describes.
What does not exist yet is the filing. The Patch the Planet site currently lists two disclosures: CVE-2026-111497 in Brotli, and CVE-2026-109618 and CVE-2026-109619, the PHP flaws known as php2shell. Java4Shell is not among them. OpenAI's own Patch the Planet post of 21 October describes the PHP response — and names the model that found it, which was GPT-5.6 Sol, not GPT-6 Cyber. The programme's first headline bug was found with the predecessor.

That is not a contradiction; it is a sequencing fact, and it matters for anyone reading the coverage as a capability claim about one model. Patch the Planet is a coordination framework with named partners and a published five-stage response — validate and fix upstream, give affected organisations time, coordinate with government, prepare updates across products, publish guidance. Java4Shell ran through the parts of that framework that concern a single upstream: OpenJDK and Oracle patched on disclosure day, and Calif held back the product-specific chains. What is missing is the OpenAI post that would put the finding inside the programme on the record.
What a search like this costs to run
The economics are the part a defender can actually act on, and they invert the intuition most teams bring. If the reported figures hold, discovery cost a few hundred dollars and the exploit another two hours of the same. The expensive part of the operation was never the inference.
That is consistent with what OpenAI published about its own Linux kernel scan a fortnight before the Cyber launch: 2,308 candidates, 1,724 reproduced, 948 unique privilege-escalation exploits, $1,213,430 in API credits, and 61 fixes upstream ten days later. Finding is cheap relative to fixing, and the constraint sits in triage and disclosure, not in the token bill. A team budgeting for this class of work should budget for the human review at several times the model spend.
It is also where a routing layer earns its keep rather than being a slogan. The pipeline has stages with genuinely different model requirements — hypothesis generation wants the widest, cheapest search you can afford; validation wants a model that can run and read a crash; patch generation wants long context over a repository. Running all three on one model means paying the most expensive stage's rate for the cheapest stage's work. Pointing each stage at a different model through one API key across more than 200 models, at provider list price with 0% markup, keeps the pipeline in one bill and one credential instead of three contracts.
One thing to be clear about: GPT-6 Cyber is not in the OrcaRouter catalogue, and cannot be until Daybreak Red approval exists for the account calling it. What we do carry is the general ladder it was derived from — GPT-6 Astra at $10/$50 per million tokens among others — which is the part of a security pipeline that does triage, patch generation and code review rather than exploit development. Automatic failover matters most at exactly the stage where a model is new and its rate limits are unknown, which describes the discovery stage of a pipeline like this one.
What to watch
Three things will decide how this reads in six months.
The first is whether the withheld chains surface in the wild before they surface in a paper. Calif's decision to publish the vulnerability and the general technique but hold the product-specific exploits is the responsible version of disclosure, and it only works if the patch rate beats the reverse-engineering rate. Oracle's update is out; the population of unpatched 17.0.x builds is the variable.
The second is whether Java4Shell reaches CISA's Known Exploited Vulnerabilities list. It is not there now, and the gap between "critical" and "exploited" is where most enterprise prioritisation arguments happen.
The third is whether OpenAI puts its own account on the record. A technical write-up naming the model, the prompts and the cost would convert a reported claim into a documented one, and it would be the first public evidence of what a Cyber-class model does on a target nobody chose for it in advance. Until then, the bug is the fact and the attribution is the story.
Compared in this article2
Detected from this article · Benchmarks: Artificial Analysis · updated daily
