Repository navigation
Mitigate CVE-2026-114938 (Java4Shell) by disabling Base64 intrinsics - #55294
Diogo-Rego wants to merge 1 commit into
Conversation
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>
729bec7 to
783a39a
Compare
|
Thanks for the PR; for now we are not planning on doing a release with enabling Update container images will be released as soon as OpenJDK fixes are available, we are actively monitoring that and will do a re-spin of container images as soon as possible. In the meantime we recommend everyone applying the mitigation ( |
Mitigation for CVE-2026-114938 (Java4Shell). See keycloak/keycloak#55294 (comment).
|
Keycloak container images for 26.8 have been updated to Red Hat OpenJDK 21.0.13.1, which includes fixes for CVE-2026-114938. The updated tags include If you are not using the container images or building your own check if your OpenJDK vendor has released updates. Fixed As of publishing Oracle and Red Hat have released updates. Eclipse Temurin |
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).