Repository navigation
Mitigate CVE-2026-114938 (Java4Shell) by disabling Base64 intrinsics - #55294
Open
Diogo-Rego wants to merge 1 commit into
Open
Diogo-Rego wants to merge 1 commit into
Diogo-Rego wants to merge 1 commit into
Conversation
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
An unescaped parenthesis breaks the Windows launcher's option-selection control flow, and shared launcher tests lack an explicit assertion protecting the security mitigation.
No open issues 🎉
What changed in this PR
This PR adds JVM defaults intended to mitigate the reported Base64 intrinsic vulnerability in Keycloak server launchers and the Operator process.
Changes:
- Add
-XX:-UseBASE64Intrinsicsand explanatory comments to the Unix and Windows launcher defaults. - Add the same flag to the Operator container’s Java entrypoint.
| File | Description |
|---|---|
quarkus/dist/src/main/content/bin/kc.sh |
Disables Base64 intrinsics in default Unix JVM options. |
quarkus/dist/src/main/content/bin/kc.bat |
Adds the mitigation to default Windows JVM options. |
operator/Dockerfile |
Disables Base64 intrinsics for the Operator JVM. |
Review effort: Balanced
Disables OpenJDK hardware-accelerated Base64 intrinsics in default JVM options to protect against heap out-of-bounds write / memory corruption (CVE-2026-114938) on x86-64 processors supporting AVX-512 VBMI instructions. Closes keycloak#55293 Signed-off-by: Diogo Rego <diego.arruda.amaral@gmail.com>
Diogo-Rego
force-pushed
the
fix/cve-2026-114938-java4shell-mitigation
branch
from
November 17, 2026 23:28
729bec7 to
783a39a
Compare
codeswhite
approved these changes
Nov 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR disables OpenJDK hardware-accelerated Base64 decoding intrinsics (
-XX:-UseBASE64Intrinsics) in default JVM options acrosskc.sh,kc.bat, and the Keycloak Operator Dockerfile.This mitigates the critical CVE-2026-114938 (Java4Shell), which affects HotSpot C2 compiler Base64 intrinsics on x86-64 CPUs with AVX-512 VBMI instruction support. In default configurations, processing malformed Base64 data prior to authentication (such as HTTP
Authorization: Basicheaders, SAML assertions, and JWTs) can trigger an out-of-bounds write / memory corruption.Disabling the intrinsic serves as the recommended mitigation until vendor-patched OpenJDK packages are broadly distributed in base container images.
Related Issue
Closes #55293
Verification & Testing
kc.shinjects-XX:-UseBASE64Intrinsicsinto the active JVM process (/proc/1/cmdline).