Skip to content
Memory corruption Write-up Advanced

Java4Shell: pre-auth RCE flaw in Java 17 puts servers at risk (CVE-2026-114938)

A memory corruption flaw in OpenJDK's Base64 decoder can let an attacker run code remotely, sometimes without authentication, when attacker-controlled Base64 data reaches the decoder on affected x86-64 hardware. The text reports that Calif claims remote code execution against several products, but other researchers have so far only reproduced crashes and memory leaks.

aikido.dev

Published on aikido.dev

Oracle Java SE 17 | Java 17 releases before 17.0.21.1 | 17.0.21.1 |

The author, on aikido.dev

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

The optimized decoder miscalculates the store mask for the padded tail of its input, so it writes past the end of the output buffer.

Impact

Calif reports remote code execution against default configurations of several products without authentication and against others after authentication, but other researchers have so far reproduced only crashes and memory leaks, and no exploitation in the wild has been confirmed.

What the attacker needed

Java 17, 21, 25 or 27 before fixed build; x86-64 CPU with AVX-512 VBMI; JVM not started with -XX:UseAVX=2; Attacker-controlled Base64 reaches decoder

The fix

Oracle has released fixed builds [redacted], [redacted], [redacted] and [redacted], and affected JVMs can be started with -XX:-UseBASE64Intrinsics as a temporary workaround.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

Java's Base64 decoder turns encoded text back into raw bytes. A bug in its fast path can write past the end of a buffer, which may let an attacker who controls the input run their own code on the server. Only certain newer x86-64 processors are affected, and fixes are available.

What is Memory corruption?

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.

Similar reports

View all

Same bug class and techniques, clearest first.

Memory corruption

The lesson behind this report.

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.