Back to technology news
Programming & Development

Cloudflare WAF adds six rules to detect Java4Shell CVE-2026-114938 while patches roll out

On November 17, 2026, security researcher Calif disclosed Java4Shell (CVE-2026-114938), a memory-corruption flaw in OpenJDK's Base64 decoder that can lead to remote code execution. Under CVSS 4.0 the vulnerability scores 9.2 out of 10 and affects OpenJDK 17.0.6 and newer, including distributions from 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. The flaw impacts x86-64 processors with AVX-512 VBMI support such as Intel Xeon Ice Lake, Sapphire Rapids, Emerald Rapids and Granite Rapids, or AMD EPYC and Ryzen Zen 4 or newer; ARM64 processors are not affected.

The vulnerability allows a remote attacker with no credentials to send malformed Base64 data to a Java application and overwrite memory adjacent to the decoded output. Calif demonstrated pre-authentication remote code execution against Keycloak, Atlassian Jira, Atlassian Confluence, JFrog Artifactory, Jenkins and PingFederate in default configurations, and post-authentication remote code execution against Apache Kafka, Apache Solr, Elasticsearch, Gerrit and Spinnaker. The bug sits in handwritten assembly handling final input characters; when padding appears in an invalid position the routine calculates a negative output length that becomes a full 64-byte write, corrupting neighboring memory before the application can reject the data.

Cloudflare has released six new rules in the Cloudflare Managed Ruleset (Ruleset ID efb7b8c949ac4650a09736fc376e9aee) designed to detect malformed Base64 input patterns associated with Java4Shell. The rules are available on Pro, Business and Enterprise plans and are enabled by default with the Log action because malformed input and some benign application-specific token formats can resemble exploitation attempts. Blocking by default could disrupt legitimate traffic. Customers can review matching requests in Security Events and change the rule action to Block once they confirm it does not affect legitimate traffic. Rule IDs include 5de9b20a45ea45d3841919ab4d718bf4 for Malformed Base64 Header and 46bb4172813e471ea62d31c02337b51d for Malformed Base64 Body Value.

The WAF provides an additional layer of defense but is not a replacement for patching Java runtimes. Java4Shell can be reached through paths a WAF does not see, such as outbound TLS responses, and the only complete fix is to update the Java runtime. Cloudflare analysts will continue to monitor attack activity and update rules as new techniques appear. New managed rules can block the exploit when malformed Base64 arrives in an HTTP request passing through Cloudflare, but cannot block every path to the vulnerable decoder, including encoded or nested data, non-HTTP protocols, outbound connections and traffic that bypasses Cloudflare entirely.

While the managed rule is the primary way to block malformed Base64 triggers at the edge, Cloudflare WAF Attack Score (and its remote code execution sub-score cf.waf.score.rce on Enterprise plans) offers a complementary layer of protection. Because CVE-2026-114938 is a binary heap-corruption vulnerability, an attacker rarely achieves full remote code execution with a single trigger string alone; turning a JVM heap overflow into RCE over HTTP almost always requires a multi-stage or multi-parameter exploit chain. Attack Score can inspect and flag secondary payloads including heap grooming, triggering parameters, second-stage payloads such as shell execution primitives or Java class-loading gadgets, and post-exploitation activity attempting to interact with in-memory webshells or pass OS commands to the compromised JVM.

Cloudflare also runs Java and, within an hour of the patches being published, began rolling out a JVM startup option that disables the accelerated Base64 routine containing the bug on all Java workloads, falling back to the standard implementation. The majority of Cloudflare's Java workloads are not scheduled on vulnerable systems, but the company is rolling out patched configuration to all machines as a precaution. No indication so far shows Java4Shell was exploited on Cloudflare infrastructure. The fix requires updating every Java runtime and restarting services that use it; while patching, users should review the new managed rule's matches and switch it to Block if on a paid plan, and layer Attack Score to catch remote code execution payloads that signature-based rules may miss.

Source credits

By Denzil Correa from Cloudflare Blog. Edited by SetuGeo.

More technology news

Browse all technology news