Skip to content
Attack Surface Management

Java4Shell (CVE-2026-114938): Heap Overflow RCE in OpenJDK – Advisory + Nuclei Detection

xer0dayz · · 29 min read

CVE-2026-114938, nicknamed Java4Shell, is a heap-based buffer overflow in the code the Java virtual machine uses to decode Base64 on modern x86-64 processors. Oracle and the OpenJDK project patched it on 17 November 2026 in an out-of-band Critical Security Patch Update, the same day the researchers at Calif published their write-up. Calif reports unauthenticated remote code execution against Jenkins, Jira, Confluence, Keycloak, JFrog Artifactory and PingFederate. All of them decode attacker-supplied Base64 (a login header, a token, a SAML message) before they know who you are. CISA’s alert the same evening said the flaw “requires immediate patching”. Java runs on nearly every enterprise network, so the question for most teams is not whether they run an affected JDK but how many, where, and on which hardware.

This post is three things. First, a plain-English explanation of the bug and the two conditions that decide whether a given JVM is actually exploitable: the build and the CPU. Second, two free, passive Nuclei templates, which nobody has published to the official ProjectDiscovery repository yet. One reads the running JVM build from exposed management endpoints and the other finds the six applications Calif exploited before login. Both were verified against real Temurin 17, Temurin 21 and Java 8 runtimes. Third, a local check that reads build, CPU flags and JVM flags together, including JVMs running inside containers, plus how to sweep a whole attack surface with Sn1per. Java4Shell was found by Quang Luong of Calif, with exploit improvements by Jenish Rakholiya.

One rule before anything else: do not use the public trigger as a “test”. The proof-of-concept input is tiny and looks harmless, but on a vulnerable JVM it is a real 64-byte out-of-bounds write into the heap. It can crash a production service, and a successful attempt against a system you do not own is an intrusion. Every check in this post reads a version string, a CPU flag or a JVM option. None of them sends Base64 to anything.

CVE-2026-114938 at a glance

Field Value
CVE CVE-2026-114938, “Java4Shell”
Class Heap-based buffer overflow, CWE-122 (CISA-ADP); Red Hat files it as CWE-787
Component HotSpot C2 x86-64 intrinsic for java.util.Base64.Decoder (AVX-512 VBMI path), Oracle component “Compiler”
Impact Pre-authentication remote code execution or memory disclosure, in any application that Base64-decodes attacker input
CVSS 8.1 High, CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H (Oracle, the CNA). Red Hat: 9.8. Calif: CVSS 4.0 9.2
Affected OpenJDK 17.0.6 and later on the 17, 21, 25 and 27 lines, plus every downstream build; Oracle Java SE 8u511-perf; Oracle GraalVM for JDK 17/21; GraalVM EE 21.3.20.0.3
Fixed Oracle/OpenJDK 17.0.21.1, 21.0.13.1, 25.0.5.1, 27.0.1.1 and 8u513-perf (vendor builds below)
Hardware precondition x86-64 CPU with AVX-512 VBMI: Intel Xeon Ice Lake and later, AMD Zen 4 and later. ARM64 is not affected
Workaround -XX:-UseBASE64Intrinsics (or -XX:UseAVX=2, x86-64 only)
Exploitation Public crash PoC; product-specific RCE chains withheld by Calif. No reported in-the-wild exploitation. Not in CISA KEV (catalog 2026.11.17)
Fix now Upgrade the JDK, restart every JVM, rebuild container images. Use the flag where you cannot do that today

What is Java4Shell (CVE-2026-114938)?

Base64 is everywhere in Java applications: HTTP Basic authentication credentials, every segment of a JWT, SAML assertions, session cookies, file uploads embedded in JSON. Because it is everywhere, the JVM accelerates it. When the C2 just-in-time compiler sees a hot call into java.util.Base64.Decoder, it replaces the Java code with a hand-written machine-code stub, an intrinsic. On processors that support the AVX-512 VBMI instruction set, that stub decodes 64 bytes of input at a time using vector byte-permute instructions, and it writes its output with a masked vector store, so that only the valid bytes of the final block are written.

The bug is in how that mask is calculated for the padded tail of the input. Calif’s analysis shows that for a short, malformed input of a particular length ending in padding, the stub computes the remaining output length as a small negative number. That value underflows into an all-ones mask, and the stub then writes a full 64-byte vector starting near the end of an output buffer that was sized for only a few dozen bytes. The result is up to 62 bytes written past the end of a heap object. The attacker controls what gets written because it is decoded from their own input. In a managed runtime that is the worst kind of bug: the attacker writes into neighbouring objects in the Java heap, and Calif turned that into both remote code execution and a memory-disclosure variant it calls “JavaBleed”, which can leak keys and tokens from the process.

Two things make it more serious than a typical JIT bug. The vulnerable path is reached through a standard library API, not an obscure feature, so it does not matter what framework an application uses, only whether it decodes Base64 that an attacker supplies. And the decode usually happens before authentication, because decoding the credential is how the application finds out who you are. A Basic-auth header or a bearer token is parsed on the first request, by design.

The bug also has a strict hardware gate. The faulty stub is only used when the CPU has AVX-512 VBMI and the JVM is running with AVX-512 enabled. On any other CPU the JVM uses a different, unaffected code path. The same container image can therefore be exploitable on one node and inert on the next, which is covered in its own section below.

A note on the name. “Java4Shell” follows Log4Shell and Spring4Shell, but unlike those it is a flaw in the Java runtime itself rather than in a library. Upgrading an application does nothing if it still runs on an affected JVM. Some search engines normalise the name to “Java Shell” or “Java2Shell”; they all mean CVE-2026-114938.

Three scores, one bug

The CVSS numbers do not agree, and it is worth knowing why before someone in a meeting quotes one. Oracle, the CNA and the source NVD currently displays (NVD status: Undergoing Analysis, as of 18 November), scores it 8.1 High with Attack Complexity: High, reflecting the CPU precondition and the per-application work an exploit needs. Red Hat scores it 9.8 with Attack Complexity: Low. Calif scores it 9.2 Critical under CVSS 4.0. The CWE differs too: CISA-ADP assigns CWE-122 (heap-based overflow), Red Hat CWE-787 (out-of-bounds write). These are differences of scoring judgment, not of fact. For an internet-facing Jira or Keycloak on Ice Lake or Zen 4 hardware, defend for the 9.8.

Java4Shell affected versions and fixed builds

The affected range starts at OpenJDK 17.0.6, the update that brought the AVX-512 Base64 decoder to the 17 line, and runs through every later release that predates the November fix. Standard Java 8 and Java 11 do not contain the decoder and are not affected. The one Java 8 exception is Oracle’s Java SE 8 Enterprise Performance Pack, which carries the newer JIT.

Distribution Affected Fixed build
Oracle Java SE / OpenJDK 17 17.0.6 through 17.0.21 (NVD lists Oracle 17.0.21.0.3) 17.0.21.1
Oracle Java SE / OpenJDK 21 21 through 21.0.13 (Oracle 21.0.13.0.3) 21.0.13.1
Oracle Java SE / OpenJDK 25 25 through 25.0.5 (Oracle 25.0.5.0.3) 25.0.5.1
Oracle Java SE / OpenJDK 27 27 through 27.0.1 (Oracle 27.0.1.0.3) 27.0.1.1
Oracle Java SE 8 Performance Pack 8u511b33-perf 8u513-perf
Eclipse Temurin 17.0.21+9 and earlier, 21.0.13, 25.0.5, 27.0.1 17.0.21.1+2, 21.0.13.1+2, 25.0.5.1+2, 27.0.1.1+4
Amazon Corretto earlier 17/21/25/27 builds 17.0.21.1.2, 21.0.13.1.2, 25.0.5.1.2, 27.0.1.1.4
Oracle GraalVM for JDK 17.0.21.0.3, 21.0.13.0.3 vendor update, Nov 2026 CSPU
Oracle GraalVM Enterprise 21.3.20.0.3 vendor update, Nov 2026 CSPU
Microsoft Build of OpenJDK, Azul Zulu, BellSoft Liberica, SAP SapMachine, Red Hat affected per Calif check the vendor’s advisory
JDK 18-20, 22-24, 26 (non-LTS) contain the decoder no fix: end of life

Three traps hide in that table.

Read the fourth number. The fix shipped as an emergency update, so the fixed builds have a fourth version component: 17.0.21.1, not 17.0.21. The October releases 17.0.21, 21.0.13, 25.0.5 and 27.0.1 are all vulnerable, and many dashboards will show them as “latest” for a few more days. java -version printing 17.0.21 means you are not patched.

End-of-life feature releases will never be fixed. JDK 18, 19, 20, 22, 23, 24 and 26 contain the same decoder and are past end of support. Amazon’s own tracker lists Corretto 22, 23, 24 and 26 as “No fix planned”. If anything in your estate runs one of these, the only remediation is moving it to 21.0.13.1 or 25.0.5.1.

Distribution packages may not move the version string. Red Hat, Debian and Ubuntu routinely backport security fixes into their own builds without changing the upstream version, and Red Hat’s page still lists java-17-openjdk and java-21-openjdk as under investigation. On a distro-packaged JDK, the package changelog is the source of truth, not java -version. An approved update in your patch tool is not an installed one either, and an installed one does nothing for a JVM that has not been restarted.

Am I vulnerable on ARM64, Graviton or older Xeons?

This is the question that will save the most time, because it can take a large part of most fleets out of the emergency queue. The vulnerable stub only runs when the processor supports AVX-512 VBMI and the JVM is using AVX-512 (UseAVX=3). On Linux, Calif’s guidance is that all four of avx512f, avx512bw, avx512vbmi and bmi2 must appear in the CPU flags.

Platform Exposure
Intel Xeon Ice Lake, Sapphire Rapids, Emerald Rapids, Granite Rapids Exposed (has AVX-512 VBMI)
AMD EPYC and Ryzen, Zen 4 and later Exposed
Intel Skylake-SP and Cascade Lake Xeons Not exposed (AVX-512 without VBMI)
AMD Zen 3 and earlier, older Intel, any AVX2-only CPU Not exposed
ARM64: AWS Graviton, Ampere, Apple Silicon Not affected

Not exposed is not the same as not vulnerable, for two reasons. First, cloud fleets move. The same AMI or container image runs on whatever instance type the scheduler gives it. An autoscaling group that mixes a Cascade Lake family with an Ice Lake or Zen 4 family is exploitable on some nodes and not others, and a routine instance-type upgrade quietly turns a dormant JVM into an exploitable one. Second, what matters is the CPU the guest sees, and hypervisors can mask or expose instruction-set flags. Check /proc/cpuinfo inside the VM or container host, not the hardware spec sheet. Treat every affected build as needing the patch. CPU flags decide how urgent it is, not whether it is needed.

Which applications are exploitable before login?

Calif’s list, repeated by Tenable and Censys, is explicitly not exhaustive. It is the list of products the researchers exploited, not the list of products that are safe.

Pre-authentication RCE demonstrated Post-authentication RCE demonstrated
Atlassian Jira Apache Kafka broker
Atlassian Confluence Apache Solr
Jenkins Elasticsearch
Keycloak Gerrit
JFrog Artifactory Spinnaker
PingFederate

The pattern behind the left-hand column is how each product handles credentials. Tenable names Apache Tomcat’s Basic authentication and the java-jwt library as routes that reach the decoder before a user logs in. Anything that accepts Authorization: Basic, parses a bearer JWT, or consumes a SAML message on an unauthenticated endpoint decodes attacker Base64 on the first request. That describes most single sign-on products and almost every developer tool with an API. Your own Spring or Jakarta services count too. If your application decodes a token in a filter, it is on the list even though no researcher has written it down.

Several of these products ship their own JDK. Jira, Confluence and Artifactory installers and official container images bundle a runtime, so patching the system Java does not patch them. Check the JDK the process actually runs, which the local check below does, and follow each vendor’s guidance for updating its bundled runtime. We covered the 2022 Confluence OGNL flaw in CVE-2022-26134 detection and this year’s Artifactory issue in CVE-2026-82329. The same servers keep appearing on these lists because they are internet-facing, run as privileged service accounts and hold everyone’s secrets.

How the Java4Shell exploit chain works

The delivery vehicle is whatever field the target decodes before authentication. For a server using HTTP Basic authentication it is as simple as a request with a crafted credential header:

GET /login HTTP/1.1
Host: target.example
Authorization: Basic [REDACTED - malformed padded Base64 of a specific length]

For a JWT-based product the same bytes ride inside one segment of a bearer token, and for a SAML product inside the encoded assertion. There are three stages. First the input has to reach the decoder enough times for C2 to compile the hot method and swap in the intrinsic; until then the Java fallback decodes it safely, so a single request does nothing. Then the malformed tail triggers the out-of-bounds store and corrupts whatever object sits next to the output buffer. Finally the attacker turns that corruption into something useful: reading adjacent memory back out (“JavaBleed”), or overwriting object metadata to reach code execution. Calif is clear that the last stage differs per application, which is why the CVSS AC:H rating exists and why the product-specific chains are being withheld. A failed attempt typically crashes the JVM, and an attacker can usually retry after the service restarts.

We are deliberately not publishing a working exploit, the trigger string, or the per-product heap grooming here, consistent with our earlier SharePoint CVE-2026-50522 advisory. Defenders do not need any of it to find and fix affected JVMs.

Is Java4Shell being exploited?

As of 18 November 2026: no in-the-wild exploitation has been reported, and the CVE is not in CISA’s Known Exploited Vulnerabilities catalog (catalog version 2026.11.17, checked directly). Tenable, Sophos and Censys all say they are not aware of exploitation. CISA’s coordinator SSVC entry on the NVD record reads exploitation “none”, automatable “no”, technical impact “total”. CISA published an alert, not a KEV listing.

That will not last long. Calif published a self-contained proof of concept that demonstrates the corruption, the mechanism is fully described in public, and several third parties already claim working exploits, which we have not verified. Calif also says it found the bug in about three hours of work and under $200 of model tokens. That is a good indicator of how quickly others will reproduce the per-product chains. Rapid7 shipped authenticated vulnerability checks in its 17 November content release. On GitHub, some of the new “Java4Shell scanners” contain PoC code that sends the trigger. Read any community tool before you point it at production.

Am I affected? Quick manual checks

The authoritative check is local, because three facts decide exposure and two of them are invisible from the network.

1. The build. Check the JDK every service actually runs, not just the one on your PATH:

java -version 2>&1 | head -1
# Every running JVM and the binary behind it
for p in $(pgrep -x java); do echo "$p $(readlink /proc/$p/exe)"; done
# The exact build a running JVM reports (same user or root)
jcmd <pid> VM.version

Fixed builds end in .1 (17.0.21.1, 21.0.13.1, 25.0.5.1, 27.0.1.1) or carry a vendor build that includes them (Corretto 17.0.21.1.2, Temurin 21.0.13.1+2).

2. The CPU. All four flags present means the vulnerable stub can run:

grep -m1 '^flags' /proc/cpuinfo | tr ' ' '\n' | grep -E '^(avx512f|avx512bw|avx512vbmi|bmi2)$'

3. The JVM’s effective flags on this CPU. UseAVX must be 3 for the AVX-512 stub to be used:

java -XX:+PrintFlagsFinal -version 2>/dev/null | grep -E ' (UseAVX|UseBASE64Intrinsics) '

A measured caveat: do not use UseBASE64Intrinsics alone as the exposure signal. On our AVX2-only test host, real Temurin 21 and Debian’s OpenJDK 25 both report UseBASE64Intrinsics = true (they have other, unaffected Base64 stubs for AVX2), while Temurin 17 reports false. UseAVX = 2 and the missing CPU flags are what show the host is not exposed. On Ice Lake or Zen 4 hardware, expect UseAVX = 3.

4. Whether the workaround is actually applied to the running process, not just written in a config file:

for p in $(pgrep -x java); do
  tr '\0' ' ' < /proc/$p/cmdline | grep -qE -- '-XX:-UseBASE64Intrinsics|-XX:UseAVX=[0-2]' \
    && echo "$p mitigated" || echo "$p NOT mitigated"
done

From outside, the best you can do is read the JVM build from a management endpoint that exposes it, which is what Template 1 below does. That tells you the build and nothing about the CPU. A host that discloses nothing is unknown, not clean.

Java4Shell detection: Nuclei templates for CVE-2026-114938

There is no official CVE-2026-114938 template in the ProjectDiscovery repository yet (the path returns 404 as of 18 November). There is no safe way to detect this remotely by behaviour, because the only behavioural signal is the memory corruption itself. Both templates below are therefore passive. They split the job the way a defender actually needs it split: which JVMs are on an affected build, and which pre-auth targets are reachable at all. Community templates exist, and Ostorlab has merged a remote detector. Ours adds per-line matcher names, EOL handling and the exposure fingerprint for the six named products.

Template 1: the JVM build, from exposed management endpoints

Spring Boot Actuator, Solr, Elasticsearch/OpenSearch, Hadoop-style /jmx and Jolokia all report the running JVM version, and all are commonly left reachable without authentication. The template reads the version from whichever answers first and gates it per release line. It never sends Base64.

id: CVE-2026-114938

info:
  name: OpenJDK / Oracle Java SE - Base64 Intrinsic Heap Overflow "Java4Shell" (CVE-2026-114938) - JVM Build Disclosure
  author: xer0dayz
  severity: high
  description: |
    CVE-2026-114938 ("Java4Shell") is a heap-based buffer overflow (CWE-122) in the
    x86-64 HotSpot C2 intrinsic that accelerates java.util.Base64.Decoder with
    AVX-512 VBMI instructions. This template is NON-DESTRUCTIVE: it reads the
    running JVM build from unauthenticated management endpoints and flags builds
    below the fixed release on each line. It never sends Base64 to the target.
    A hit does NOT prove the host CPU has AVX-512 VBMI; confirm locally.
  remediation: |
    Upgrade to Oracle/OpenJDK 17.0.21.1, 21.0.13.1, 25.0.5.1 or 27.0.1.1 (or the
    vendor equivalent), restart every JVM and rebuild container images. Interim:
    -XX:-UseBASE64Intrinsics. JDK 18-20, 22-24 and 26 are EOL and get no fix.
  reference:
    - https://www.oracle.com/security-alerts/cspunov2026.html
    - https://openjdk.org/groups/vulnerability/advisories/2026-11-17
    - https://calif.io/java4shell
    - https://nvd.nist.gov/vuln/detail/CVE-2026-114938
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
    cvss-score: 8.1
    cve-id: CVE-2026-114938
    cwe-id: CWE-122
  metadata:
    verified: false
    max-request: 7
    vendor: oracle
    product: jdk
  tags: cve,cve2026,java4shell,java,openjdk,jdk,jvm,heap-overflow,rce,exposure,passive

http:
  - method: GET
    path:
      - "{{BaseURL}}/actuator/env"
      - "{{BaseURL}}/env"
      - "{{BaseURL}}/solr/admin/info/system?wt=json"
      - "{{BaseURL}}/_nodes/_local/jvm"
      - "{{BaseURL}}/jmx?qry=java.lang:type=Runtime"
      - "{{BaseURL}}/jolokia/read/java.lang:type=Runtime/VmVersion"
      - "{{BaseURL}}/actuator/jolokia/read/java.lang:type=Runtime/VmVersion"

    stop-at-first-match: true
    redirects: false

    matchers-condition: or
    matchers:
      - type: dsl
        name: jdk17-17.0.6-to-below-17.0.21.1
        dsl:
          - "jvm_version != '' && compare_versions(jvm_version, '>= 17.0.6', '< 17.0.21.1')"

      - type: dsl
        name: jdk21-below-21.0.13.1
        dsl:
          - "jvm_version != '' && compare_versions(jvm_version, '>= 21', '< 21.0.13.1')"

      - type: dsl
        name: jdk25-below-25.0.5.1
        dsl:
          - "jvm_version != '' && compare_versions(jvm_version, '>= 25', '< 25.0.5.1')"

      - type: dsl
        name: jdk27-below-27.0.1.1
        dsl:
          - "jvm_version != '' && compare_versions(jvm_version, '>= 27', '< 27.0.1.1')"

      - type: dsl
        name: jdk-eol-feature-release-no-fix-available
        dsl:
          - "jvm_version != '' && (compare_versions(jvm_version, '>= 18', '< 21') || compare_versions(jvm_version, '>= 22', '< 25') || compare_versions(jvm_version, '>= 26', '< 27'))"

    extractors:
      - type: regex
        name: jvm_version
        part: body
        group: 1
        internal: true
        regex:
          - '"java\.version"\s*:\s*\{\s*"value"\s*:\s*"([0-9][^"]*)"'
          - '"java\.version"\s*:\s*"([0-9][^"]*)"'
          - '"jvm"\s*:\s*\{[^{}]*?"version"\s*:\s*"([0-9][^" ]*)'
          - '"VmVersion"\s*:\s*"([0-9]+(?:\.[0-9]+){0,4}(?:\+[^"]*)?)"'
          - '"attribute"\s*:\s*"VmVersion"[^}]*\}\s*,\s*"value"\s*:\s*"([0-9]+(?:\.[0-9]+){0,4}(?:\+[^"]*)?)"'

      - type: regex
        name: jvm_build
        part: body
        group: 1
        regex:
          - '"java\.version"\s*:\s*\{\s*"value"\s*:\s*"([0-9][^"]*)"'
          - '"java\.version"\s*:\s*"([0-9][^"]*)"'
          - '"jvm"\s*:\s*\{[^{}]*?"version"\s*:\s*"([0-9][^" ]*)'
          - '"VmVersion"\s*:\s*"([0-9]+(?:\.[0-9]+){0,4}(?:\+[^"]*)?)"'
          - '"attribute"\s*:\s*"VmVersion"[^}]*\}\s*,\s*"value"\s*:\s*"([0-9]+(?:\.[0-9]+){0,4}(?:\+[^"]*)?)"'

A few design decisions are worth explaining, because each one is a way a version template silently lies. Each extractor pattern is keyed to one endpoint’s JSON shape, so only one can match a given response. A pattern that matched twice would bind the variable to a list, compare_versions() would return false, and every host would read clean. Captures must start with a digit, which rejects the ****** that Spring Boot 3 returns for masked /actuator/env values. compare_versions() treats Temurin’s +10-LTS as build metadata and orders Oracle’s five-part 17.0.21.0.3 below 17.0.21.1, both of which we tested. A Java 8 string like 1.8.0_512 does not parse and stays silent, which is correct. JMX and Jolokia report the HotSpot VM version, which on Java 8 looks like 25.512-b09, so those two patterns accept only the JDK 9+ form.

Template 2: the six pre-auth targets

The products Calif exploited before login do not disclose their JVM build remotely. What they do disclose is themselves. This template fingerprints them from their public login pages and discovery documents and reports each with a named matcher, so the output reads as a to-do list: “Keycloak here, verify its JDK”.

id: java4shell-preauth-app-exposure

info:
  name: Java4Shell (CVE-2026-114938) - Pre-Auth Exploitable Application Exposure
  author: xer0dayz
  severity: medium
  description: |
    Fingerprints the six applications Calif reported as exploitable BEFORE login
    via CVE-2026-114938: Jenkins, Jira, Confluence, Keycloak, JFrog Artifactory and
    PingFederate. Exposure triage, not a vulnerability check: a hit means "a
    Java4Shell pre-auth target is reachable here - verify its JDK build and CPU".
    Ordinary GET requests only; never sends Base64, credentials, a JWT or SAML.
  reference:
    - https://calif.io/java4shell
    - https://nvd.nist.gov/vuln/detail/CVE-2026-114938
  classification:
    cve-id: CVE-2026-114938
    cwe-id: CWE-122
  metadata:
    verified: false
    max-request: 9
  tags: java4shell,cve2026,java,exposure,jenkins,jira,confluence,keycloak,artifactory,pingfederate,tech,passive

http:
  - method: GET
    path:
      - "{{BaseURL}}/login"
    redirects: false
    matchers:
      - type: dsl
        name: jenkins-preauth-base64-surface
        dsl:
          - "contains(to_lower(header), 'x-jenkins:')"
    extractors:
      - type: kval
        name: jenkins_version
        kval:
          - x_jenkins

  - method: GET
    path:
      - "{{BaseURL}}/login.jsp"
      - "{{BaseURL}}/jira/login.jsp"
    stop-at-first-match: true
    host-redirects: true
    max-redirects: 2
    matchers:
      - type: word
        name: jira-preauth-base64-surface
        part: body
        words:
          - 'name="application-name" content="JIRA"'
          - 'title="JiraVersion"'
        condition: or
    extractors:
      - type: regex
        name: jira_version
        part: body
        group: 1
        regex:
          - 'title="JiraVersion" value="([0-9.]+)"'

  - method: GET
    path:
      - "{{BaseURL}}/login.action"
      - "{{BaseURL}}/wiki/login.action"
    stop-at-first-match: true
    host-redirects: true
    max-redirects: 2
    matchers:
      - type: dsl
        name: confluence-preauth-base64-surface
        dsl:
          - "contains(to_lower(header), '-confluence-') || contains(body, 'confluence-base-url')"
    extractors:
      - type: regex
        name: confluence_version
        part: body
        group: 1
        regex:
          - '<meta name="ajs-version-number" content="([0-9.]+)"'

  - method: GET
    path:
      - "{{BaseURL}}/realms/master/.well-known/openid-configuration"
      - "{{BaseURL}}/auth/realms/master/.well-known/openid-configuration"
    stop-at-first-match: true
    redirects: false
    matchers:
      - type: dsl
        name: keycloak-preauth-base64-surface
        dsl:
          - "status_code == 200 && contains(body, '/realms/master') && contains(body, 'protocol/openid-connect/login-status-iframe.html')"

  - method: GET
    path:
      - "{{BaseURL}}/artifactory/api/system/ping"
    redirects: false
    matchers:
      - type: regex
        name: artifactory-preauth-base64-surface
        part: header
        regex:
          - '(?i)x-jfrog-version:\s*Artifactory/'
    extractors:
      - type: regex
        name: artifactory_version
        part: header
        group: 1
        regex:
          - '(?i)x-jfrog-version:\s*Artifactory/([0-9]+\.[0-9]+\.[0-9]+)'

  - method: GET
    path:
      - "{{BaseURL}}/"
    host-redirects: true
    max-redirects: 2
    matchers:
      - type: word
        name: pingfederate-preauth-base64-surface
        part: body
        words:
          - '/pingfederate/dist/styles.css'
          - '/pingfederate/dist/index-bundle.js'
        condition: or

Save both and run them:

nuclei -t CVE-2026-114938.yaml -t java4shell-preauth-app-exposure.yaml -l targets.txt -o java4shell.txt

Sample output, verbatim from our lab runs (real Temurin 17 and 21 JVMs, and a Keycloak fingerprint fixture):

[CVE-2026-114938:jdk17-17.0.6-to-below-17.0.21.1] [http] [high] http://127.0.0.1:18781/actuator/env ["17.0.18"]
[CVE-2026-114938:jdk21-below-21.0.13.1] [http] [high] http://127.0.0.1:18782/solr/admin/info/system?wt=json ["21.0.11"]
[java4shell-preauth-app-exposure:keycloak-preauth-base64-surface] [http]  http://127.0.0.1:18798/realms/master/.well-known/openid-configuration

A Template 1 hit is also a finding in its own right. An unauthenticated /actuator/env or Jolokia endpoint leaks configuration and, in Jolokia’s case, often allows far worse than reading a version string. Fix the exposure while you fix the JDK.

How the templates were verified

Both templates pass nuclei -validate on v3.11.1. Template 1 was tested two ways. A 33-case boundary matrix ran against mock endpoints: every line’s lower and upper bound, Oracle five-part builds, Temurin +N builds, Java 8 and 11, every EOL line, Spring Boot 3 masked values, and every endpoint shape. A real-JVM matrix then ran a small server inside real Temurin 17.0.18, Temurin 21.0.11 and Temurin 8u512 runtimes. That server reports its own System properties and RuntimeMXBean through all five endpoint shapes, so every version string the template parsed was produced by a real JVM. Results: 17 and 21 hit on all five shapes with the correct per-line matcher, and Java 8 was silent on all five. Template 2 passed 8 fingerprint cases, including a generic OIDC provider and a plain login page that must stay silent. That is 59 of 59 cases in total. We did not test against live installs of the six products, so the fingerprints rely on their public login-page markers. That is why the metadata says verified: false.

Blind spots, stated plainly

  1. A version hit is not a CPU hit. Template 1 cannot see whether the host has AVX-512 VBMI or whether the JVM was started with the workaround. Every hit needs the local check before it is called exploitable.
  2. Distro backports can produce false positives. A RHEL, Debian or Ubuntu JDK can carry the fix while still reporting 17.0.21. Check the package changelog before escalating.
  3. Silence means unknown. Most production JVMs expose no management endpoint at all, and Spring Boot 3 masks the value by default. No hit is not a clean result; it means you need the local check or your inventory.
  4. Template 2 is triage, not detection. It finds where to look. It says nothing about the JDK underneath.
  5. Oracle’s 8u511-perf cannot be told apart from ordinary Java 8 remotely. Find it locally.

Detection script for CVE-2026-114938

cve-2026-114938-detect.py is a standalone Python 3 script with two modes. Its local mode is the authoritative check. For every java on the PATH, every path given with --java, and every running JVM process, it reports the build, the CPU flags, the effective UseAVX/UseBASE64Intrinsics values and whether each running JVM has the workaround on its command line or in JAVA_TOOL_OPTIONS. Run as root on a container host, it also checks JVMs running inside containers by executing their binary inside the container’s own root filesystem. Its remote mode reads the same endpoints as Template 1.

sudo ./cve-2026-114938-detect.py local
./cve-2026-114938-detect.py remote -f targets.txt --timeout 8 --insecure

Exit codes are built for fleet automation: 1 affected and exploitable (or not ruled out, which is always the case remotely), 3 affected build that is not exploitable on this host right now (the CPU lacks VBMI or the intrinsic is disabled; patch anyway), 0 fixed or not affected, 2 unknown. On our test host, one run found the host’s own Debian OpenJDK 25.0.4 and three containerised JVMs (Temurin 21 with the workaround, Temurin 17 without, Temurin 8). It classified them LATENT, LATENT and OK, flagged the Debian build for a changelog check, and exited 3. The script sends no Base64, and its header says so.

Detecting Java4Shell across your attack surface with Sn1per

This is a discovery problem before it is a scanning problem. The JVMs that stay vulnerable for months will not be the Jira server everyone knows about. They will be the Jenkins agent on a forgotten subnet, the Keycloak a vendor installed for a pilot, the Solr behind an internal search page, and the container images nobody has rebuilt since September. A template is only as good as its target list.

Drop both templates into Sn1per’s curated set and they run against every HTTP service Sn1per discovers:

sudo cp CVE-2026-114938.yaml java4shell-preauth-app-exposure.yaml \
       /usr/share/sniper/templates/nuclei/server/

# One host
sudo sniper -t jira.example.com -m web -w java4shell

# Everything under a domain, subdomains included
sudo sniper -t example.com -m airstrike -w java4shell

# An internal range, for the build servers and SSO that never face the internet
sudo sniper -t 10.0.0.0/24 -m discover -w java4shell-internal

To pull the findings into a ticketing or SIEM pipeline from Sn1per Professional:

curl -sk -H "X-API-Key: $SN1PER_API_KEY" \
  "https://sn1per.local/pro/api.php?action=vulnerabilities&workspace=java4shell" \
  | jq '.' | grep -iE 'CVE-2026-114938|java4shell'

Then join the two outputs. The hosts that appear in both the Template 2 exposure list and the Template 1 affected-build list are your first-hour patch queue. Exposure-only hosts are your second, and they need the local script run on them. Sn1per’s external attack surface management workflow is built for exactly this “find the forgotten ones first” problem.

There is a second reason to run this yourself. A list of every unpatched, internet-facing JVM you own, with the ones on Ice Lake hardware marked, is the most valuable document an attacker could have this week. Keep it on infrastructure you control, not in someone else’s cloud. Sn1per runs entirely self-hosted, which is the point of on-premises external attack surface management.

Which Sn1per edition fits

Capability Community Professional 2026 Enterprise
Run the CVE-2026-114938 templates Yes Yes Yes
Curated Nuclei set maintained for you Partial Yes Yes
Workspaces and scan history Basic Yes Yes
Web UI with asset risk ranking No Yes Yes
JSON API for finding export No Yes Yes
Scheduled recurring surface sweeps No Limited Yes
Multi-user, delegated workspaces No No Yes

To answer “which of our JVMs are on an affected build” once, Community plus the templates and the local script is enough. The harder question is the one Java4Shell will raise for the next year: will the next unrebuilt image, the next EOL JDK a vendor ships inside an appliance, or the next instance-type change that switches on AVX-512 show up before an attacker finds it? That is what continuous attack surface testing is for. The Professional vs Enterprise comparison covers where scheduling and delegated workspaces start to matter.

Java4Shell mitigation and remediation

  1. Upgrade the JDK to a fixed build. Oracle/OpenJDK 17.0.21.1, 21.0.13.1, 25.0.5.1, 27.0.1.1 (8u513-perf for the Performance Pack); Temurin 17.0.21.1+2, 21.0.13.1+2, 25.0.5.1+2, 27.0.1.1+4; Corretto 17.0.21.1.2, 21.0.13.1.2, 25.0.5.1.2, 27.0.1.1.4. For other vendors and distribution packages, use the vendor advisory and check the changelog. Start with internet-facing hosts on AVX-512 VBMI hardware that run one of the six named products.
  2. Restart every JVM. A new JDK on disk does nothing for a process started last month. Use the local script’s running-process list to prove nothing is left on the old build.
  3. Rebuild and redeploy container images. FROM eclipse-temurin:21 is not patched until the image is rebuilt on a fixed tag and the pods are rolled. Temurin Docker images are published only once all binaries for a version are out, so pin the fixed build explicitly rather than trusting a floating tag on day one.
  4. Update bundled runtimes separately. Jira, Confluence and Artifactory installers, many official container images and most appliances ship their own JDK. Follow each vendor’s guidance; the system Java upgrade does not reach them.
  5. Move EOL JDKs to a supported line. JDK 18-20, 22-24 and 26 will never be fixed. Their only remediation is 21.0.13.1 or 25.0.5.1.
  6. Where you cannot patch today, disable the intrinsic. Add -XX:-UseBASE64Intrinsics to every launch path: service units, wrapper scripts such as setenv.sh, container entrypoints, Helm values. Setting JAVA_TOOL_OPTIONS=-XX:-UseBASE64Intrinsics covers every JVM in an environment at once, and each JVM prints “Picked up JAVA_TOOL_OPTIONS” so you can confirm it took. Restart, then verify with the local check. Prefer this over -XX:UseAVX=2, which slows far more than Base64 and, per Tenable, stops the JVM starting on ARM if the same configuration is pushed there.
  7. Add a compensating control at the edge. CrowdSec has published a virtual-patching rule that blocks malformed Base64 tokens (32 or more characters, ending in padding, with a length that is not a multiple of four) in Authorization, cookies and known exploit parameters. Treat a WAF rule as time-buying, not a fix: Base64 reaches the JVM through many fields a WAF does not inspect.
  8. Close the management endpoints. If Template 1 found your JVM version, it found an unauthenticated Actuator, Solr admin, JMX or Jolokia endpoint. Put it behind authentication or off the network.
  9. Hunt for attempts. Look for unexplained JVM crashes (hs_err_pid*.log files, especially ones naming the Base64 decode stub or a SIGSEGV in compiled code), services that restart in loops, and bursts of malformed Basic, Bearer or SAML values in access logs. If a pre-auth target crashed repeatedly since 17 November, treat it as a possible intrusion. Rotate the credentials, keys and tokens that process held, because JavaBleed is a memory-disclosure variant even when code execution failed.

Frequently asked questions

How do I detect Java4Shell (CVE-2026-114938) on my network without crashing anything? Never send the public trigger: on a vulnerable JVM it is a real heap overflow, not a probe. Check exposure instead. Locally, read the JDK build, the CPU flags (avx512f, avx512bw, avx512vbmi, bmi2) and the JVM’s effective UseAVX value; the free detection script in this post does all three, including JVMs inside containers. Remotely, the passive Nuclei templates here read the JVM build from exposed management endpoints and fingerprint the six applications that are exploitable before login, using only ordinary GET requests.

Which applications are exploitable before login? Calif demonstrated pre-authentication remote code execution against Atlassian Jira, Atlassian Confluence, Jenkins, Keycloak, JFrog Artifactory and PingFederate, and post-authentication RCE against Apache Kafka, Apache Solr, Elasticsearch, Gerrit and Spinnaker. The list is not exhaustive. Any Java application that Base64-decodes an attacker-supplied Basic-auth header, JWT or SAML message before authentication is a candidate, including in-house services.

Am I vulnerable on ARM64, Graviton or older Xeons without AVX-512 VBMI? ARM64 systems, including AWS Graviton and Ampere, are not affected. x86-64 CPUs without AVX-512 VBMI, such as Skylake-SP and Cascade Lake Xeons, AMD Zen 3 and earlier, and AVX2-only CPUs, do not run the vulnerable decoder. Intel Ice Lake Xeon and later and AMD Zen 4 and later do. An affected build on a safe CPU is latent rather than safe: the same image becomes exploitable when it lands on newer hardware, so patch it anyway.

Does -XX:-UseBASE64Intrinsics fully mitigate Java4Shell? It removes the vulnerable code path, and Calif describes it as a full mitigation, but it only protects JVMs that were actually started with it. It has to be on every launch path, survive restarts and redeployments, and be verified on the running process. JAVA_TOOL_OPTIONS is the simplest way to apply it fleet-wide. Vendors including Tenable and Adoptium position it as an interim measure. Patch as soon as you can.

Which Corretto, Temurin and Oracle JDK builds fix CVE-2026-114938? Oracle and OpenJDK: 17.0.21.1, 21.0.13.1, 25.0.5.1 and 27.0.1.1, plus 8u513-perf for the Java 8 Performance Pack. Eclipse Temurin: 17.0.21.1+2, 21.0.13.1+2, 25.0.5.1+2 and 27.0.1.1+4. Amazon Corretto: 17.0.21.1.2, 21.0.13.1.2, 25.0.5.1.2 and 27.0.1.1.4. Plain 17.0.21, 21.0.13, 25.0.5 and 27.0.1 are still vulnerable. Standard Java 8 and 11 are not affected, and JDK 18-20, 22-24 and 26 are end of life with no fix.

Is Java4Shell being exploited in the wild? Not as of 18 November 2026. No in-the-wild exploitation has been reported, and CVE-2026-114938 is not in the CISA Known Exploited Vulnerabilities catalog. CISA has issued an alert urging immediate patching. A public proof of concept demonstrates the memory corruption, and the researchers are withholding their product-specific exploit chains for now.

Is the Java4Shell Nuclei template safe to run in production? Yes. Both templates send only ordinary GET requests for management endpoints, login pages and public discovery documents, and neither sends Base64, credentials, tokens or SAML to the target. The JVM build template does read management endpoints such as Actuator and Jolokia, which can be sensitive, so run it only against systems you are authorised to test.

Timeline and sources

  • 17 Nov 2026, 13:00 PT – Oracle and OpenJDK release fixes in an out-of-band Critical Security Patch Update; Calif publishes the Java4Shell write-up and PoC.
  • 17 Nov 2026 – CISA alert “Critical Java Vulnerability Requires Immediate Patching”; Amazon Corretto and AWS ALAS updates; Rapid7 authenticated checks; Temurin fixed builds begin publishing.
  • 17 Nov 2026, 22:18 UTC – NVD publishes CVE-2026-114938 (status on 18 Nov: Undergoing Analysis).
  • 18 Nov 2026 – Not in CISA KEV (catalog 2026.11.17); no reported in-the-wild exploitation; no official ProjectDiscovery template.

Primary sources: NVD CVE-2026-114938, Oracle CSPU November 2026, OpenJDK Vulnerability Advisory 2026-11-17, Calif: Java4Shell, CISA alert, Eclipse Temurin guidance, Amazon Linux ALAS, Red Hat CVE page, Tenable FAQ, Rapid7 ETR.

Java4Shell is the third “4Shell” in five years, and the first in the runtime itself. The lesson is the same one Log4Shell taught, at a lower layer: you cannot patch what you have not inventoried, and the runtime under your applications is part of your attack surface. Run the templates and the local script across everything you own today, starting with the internet-facing logins, and keep running them, because the next unrebuilt image will not announce itself.

Try it free

See your attack surface like a pentester would.

Sn1per finds, ranks, and exploits real vulnerabilities autonomously - the same way attackers do.