Keycloak Denial of Service (DoS) Vulnerability via JWT Token CacheGHSA-2935-2wfm-hhpv
MEDIUMGHSA-2935-2wfm-hhpv is a medium-severity (CVSS 4.9) CWE-770 vulnerability in org.keycloak:keycloak-services. The records list no fixed version yet; check the vendor advisory below and apply the mitigations in the meantime.
Exploitation Status
No confirmed exploitation observed yet
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for GHSA-2935-2wfm-hhpv.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
Where this sits among everything scored
Real-World Exposure
org.keycloak:keycloak-servicesReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Maven packages — download data is not available via public APIs for these ecosystems.
Description
A flaw was found in Keycloak. When the configuration uses JWT tokens for authentication, the tokens are cached until expiration. If a client uses JWT tokens with an excessively long expiration time, for example, 24 or 48 hours, the cache can grow indefinitely, leading to an OutOfMemoryError. This issue could result in a denial of service condition, preventing legitimate users from accessing the system.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| ☕Maven | org.keycloak:keycloak-services | all versions | No fix |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for org.keycloak:keycloak-services, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Remediation status
The records we use list no patched version of org.keycloak:keycloak-services for GHSA-2935-2wfm-hhpv. Check the maintainer's advisory, and where your build allows, override or pin the dependency away from the vulnerable range.
Mitigate without a patch
Cap what an attacker can consume: apply request size, rate and timeout limits in front of the affected component, and run it with memory and CPU limits so exhaustion degrades one worker rather than the whole service.
Fixing This On Your OS
If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.
| Product | Fixed in | Advisory |
|---|---|---|
| Red Hat Build of Keycloak | keycloak-services | RHSA-2025:4336 |
| Red Hat build of Keycloak 26.0 | rhbk/keycloak-operator-bundle:26.0.11-2 | RHSA-2025:4335 |
Frequently Asked Questions
Is GHSA-2935-2wfm-hhpv in your dependencies?
Find it across Maven, including transitive dependencies.