Java4Shell: A Java Flaw Opens Jira, Jenkins, and Keycloak to Attackers
TL;DRJava4Shell is a memory-corruption flaw in OpenJDK's accelerated Base64 decoder, and whether a server is exposed depends on its runtime, its CPU, and whether attacker-controlled input reaches that code. The hunting queries below search web, application, and endpoint telemetry for exploitation attempts and the activity that follows.
- Dor Levy,Roey Bartov
- 18 Nov 2026
- 7 minutes
Key findings
- CVE-2026-114938 (CVSS 4.0: 9.2) affects unpatched OpenJDK builds on x86-64 hosts with AVX-512, and only where an application passes attacker-controlled input to the vulnerable Base64 decoder.
- Failed attempts may crash the JVM, but memory disclosure and code execution can succeed without one.
- Three hunting queries follow the attack chain: malformed Basic credentials and request bursts in web and WAF records, then JVM crashes and remote-access commands launched by Java in Linux EDR logs.
- Nine Vega detections cover what follows a successful exploit, from reverse shells opened by Java processes to payload delivery and SSHPass lateral movement, collected with the affected versions and the mitigation in the threat brief.
Calif disclosed Java4Shell on November 17, 2026, demonstrating remote code execution across multiple widely deployed Java applications. Pre-authentication exploitation was demonstrated in Keycloak, Jira, Confluence, JFrog Artifactory, Jenkins, and PingFederate, while post-authentication exploitation was demonstrated in Apache Kafka, Apache Solr, Elasticsearch, Gerrit, and Spinnaker.
Because the vulnerability resides in the Java runtime rather than any single application, defenders must identify potentially affected systems and investigate suspicious activity that could indicate successful exploitation.
How Vega customers are protected
Vega customers are protected by nine detections that cover what follows a successful Java4Shell exploit (CVE-2026-114938), from the first shell a compromised Java process opens to the attacker moving on to other internal hosts:
- Remote access: Bash Reverse Shell via dev tcp Spawned by Java Web Process, Shell Reverse Connection via Dev TCP Redirection, Scripting Interpreter Reverse Shell, Named Pipe Reverse Shell via mkfifo, and Netcat or Socat Listener with Command Execution.
- Reconnaissance and payload delivery: Oracle EBS Post-Exploitation Linux Reconnaissance via SentinelOne, PowerShell Download Cradle Spawned by Web Server Process, and Msiexec Installing MSI from Web Server Parent.
- Lateral movement: SSHPass Credential Spraying Across Internal Hosts.
Customers also receive the linked Java4Shell threat brief, which brings together these detections, the affected OpenJDK and Oracle versions, the -XX:-UseBASE64Intrinsics mitigation, and the MITRE ATT&CK mapping.
Affected Java versions
Java4Shell (CVE-2026-114938) affects unpatched OpenJDK-based runtimes starting from Java 17.0.6, including affected builds of Java 21, 25, and 27. The vulnerability also affects multiple OpenJDK distributions, including Oracle Java, Amazon Corretto, Eclipse Temurin, and Azul Zulu.
For Oracle Java SE, the fixed versions are 17.0.21.1, 21.0.13.1, 25.0.5.1, and 27.0.1.1. Other Java distributions may use different patch version numbers. Oracle also identified its Java 8 performance build (8u511b33-perf) as affected.
Exploitation requires an x86-64 processor supporting AVX-512 VBMI and an application path that processes attacker-controlled Base64 input. ARM64 systems are not affected.
What the vulnerability does
OpenJDK HotSpot can use an AVX-512-accelerated routine to decode Base64 when the JIT compiler optimizes frequently executed code. A malformed padded tail can cause the optimized routine to calculate an incorrect write mask. In Calif's example, the final write extends 62 bytes beyond a 50-byte output array. Java may raise an IllegalArgumentException afterward, but the memory may already be corrupted.
The researchers demonstrated how arranged heap corruption could be turned into memory disclosure and, with application-specific work, remote code execution. JIT warm-up and unsuccessful attempts can leave traces; neither a crash nor a spawned shell is guaranteed.
Identifying potentially vulnerable Java applications
Start with the Java applications Calif reported as exploitable, and confirm each candidate on these points before calling it vulnerable:
- Runtime: the exact running JDK build, including bundled runtimes and containers, is unpatched.
- CPU and configuration: the host exposes
avx512f,avx512bw,avx512vbmi, andbmi2, and the vulnerable Base64 intrinsic has not been disabled. - Reachability: attacker-controlled input can reach the affected decoder, for example through an application's authentication or request-processing path. Outbound client-side paths may also matter.
What the telemetry can reveal
| Source | What to look for |
|---|---|
| Endpoint / EDR telemetry | Suspicious child processes spawned by Java applications |
| HTTP security / WAF / API gateway logs | Malformed Basic authorization padding and whether requests reached the application |
| Web / proxy / WAF / API security logs | Unusual spikes in requests to endpoints targeted by public exploit tools |
| Linux OS and audit logs | Base64 exceptions, fatal-error files, segmentation faults, abnormal Java exits |
Hunt for exploitation activity
1. Detecting malformed Base64 authentication requests
Java4Shell exploits a vulnerability in Java's optimized Base64 decoder. Attackers may attempt to trigger the vulnerable code path by sending specially crafted Base64 values through application functionality such as HTTP Basic authentication.
This query identifies HTTP Basic authentication requests containing unusually long Base64 values with malformed padding. Such requests may indicate attempts to trigger the vulnerability, particularly when directed at potentially affected Java applications.
@data_type:/WAF-and-API-Security
| where httpRequest.headers.value matches regex "(?i)^basic\\s+(?:[a-z0-9+/]{4}){8,}(?:[a-z0-9+/]{0,2}=|[a-z0-9+/]?==|===)$"
| summarize
requests = count(),
allowed_requests = countif(status_code =~ "ALLOW"),
public_poc_trigger_requests = countif(httpRequest.headers.value has "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" or httpRequest.headers.value has "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA"),
first_seen = min(timestamp),
last_seen = max(timestamp),
uris = make_set(tostring(request.uri), 5),
actions = make_set(status_code, 3)
by client = tostring(src_endpoint.ip), site = tostring(url.domain)
| order by allowed_requests desc, public_poc_trigger_requests desc, requests asc 2. Detecting Java crashes and restarts (Linux)
Failed Java4Shell exploitation attempts may cause the affected JVM to crash, potentially followed by an automatic service restart. Repeated crashes and restarts can therefore provide useful evidence of attempted exploitation, even when the original malicious request is not visible in web security logs.
This hunt identifies Linux hosts where the systemd-coredump handler is launched for a Java process or where core dump activity coincides with Java service restarts. It correlates these events within 30-minute windows to highlight potentially suspicious crash patterns.
@data_type:/EDR-Events
| where event_name in~ ("ProcessRollup2", "SyntheticProcessRollup2", "ProcessCreated", "Process Creation", "Process Create")
| where process.name in~ ("systemd-coredump", "java")
| summarize
crash_count = countif(process.name =~ "systemd-coredump" and process.cmd_line matches regex "systemd-coredump\s+\d+\s+\d+\s+\d+\s+(4|6|7|8|11)\s"),
java_task_crash_count = countif(process.name =~ "systemd-coredump" and process.cmd_line endswith " java"),
java_restart_count = countif(process.name =~ "java" and parent_process.name =~ "systemd"),
start_time = min(timestamp),
end_time = max(timestamp)
by device.hostname, timeframe = bin(timestamp, 30m)
| where java_task_crash_count > 0 or (crash_count > 0 and java_restart_count > 0) 3. Hunting suspicious remote access from Java processes (Linux)
Following successful exploitation, attackers may use a compromised Java application to establish remote access, execute reverse shells, or attempt lateral movement to other systems.
This hunt identifies Java processes spawning network utilities such as nc, ncat, socat, and sshpass, as well as shell commands involving /dev/tcp/ or named pipes. It examines both direct child processes and grandchildren of Java to identify suspicious activity that may indicate post-exploitation behavior.
@data_type:/EDR-Events
| where event_name in~ ("ProcessRollup2", "SyntheticProcessRollup2", "ProcessCreated", "Process Creation", "Process Create")
| where parent_process.name =~ "java" or grandparent_process.name =~ "java"
| where process.name in~ ("nc", "nc.traditional", "nc.openbsd", "ncat", "netcat", "socat", "telnet", "sshpass")
or process.cmd_line contains "/dev/tcp/"
or process.cmd_line contains "/tmp/"
or (process.name in~ ("sh", "bash", "dash", "zsh") and process.cmd_line contains "mkfifo")
| where not(process.cmd_line contains_cs " -U ")
| summarize
events = count(),
commands = make_set(substring(process.cmd_line, 0, 200), 10),
children = make_set(process.name, 10),
users = make_set(actor.user.name, 5),
first_seen = min(timestamp),
last_seen = max(timestamp)
by device.hostname What should defenders do?
- Patch and restart: use fixed vendor JDK builds; include bundled runtimes and rebuild container images. Check the full build number, not just Java 17 or Java 21.
- Mitigate temporarily:
-XX:-UseBASE64Intrinsicsdisables the vulnerable acceleration path. On relevant x86-64 runtimes,-XX:UseAVX=2is a broader alternative. - Reduce reachable exposure: prioritize internet-facing affected applications and narrow access where possible. HTTP filtering does not cover every possible input path.
Conclusion
Because Java4Shell lives in the JVM, the hunt starts with the runtime: identify the relevant applications, verify the JDK build and the CPU, then correlate malformed requests, high-rate warm-up activity, JVM failures, and unusual commands executed by Java. A crash strengthens an investigation, but a quiet host can still have leaked memory without ever spawning a shell. Hunting signals and temporary mitigations buy time until the affected runtimes are patched. Until then, Vega customers have coverage on what an attacker does next, and the Java4Shell brief on the Vega Threat Hub keeps it in one place.
References
- OpenJDK source: the AVX-512 Base64 decoder and its 32-byte threshold in Java 21
- #Java4Shell
- #OpenJDK
- #CVE-2026-114938
- #threat hunting
- #remote code execution
- #threat research