CVE-2022-22976 is a medium-severity (CVSS 5.3) CWE-190 vulnerability in org.springframework.security:spring-security-core. A fix is available for org.springframework.security:spring-security-core — see the affected versions and patch details below.
Integer overflow in BCrypt class in Spring Security
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.springframework.security:spring-security-core☕org.springframework.security:spring-security-coreReal-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
Spring Security versions 5.5.x prior to 5.5.7, 5.6.x prior to 5.6.4, and earlier unsupported versions contain an integer overflow vulnerability. When using the BCrypt class with the maximum work factor (31), the encoder does not perform any salt rounds, due to an integer overflow error. The default settings are not affected by this CVE.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| ☕Maven | org.springframework.security:spring-security-core | ≥ 5.2.0.RELEASE&&< 5.5.7 | 5.5.7org.springframework.security:spring-security-core:5.5.7 |
| ☕Maven | org.springframework.security:spring-security-core | ≥ 5.6.0&&< 5.6.4 | 5.6.4org.springframework.security:spring-security-core:5.6.4 |
Affected Products
active iq unified managernetappfinancial services crime and compliance management studiooraclespring securityvmwareDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for org.springframework.security:spring-security-core, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update org.springframework.security:spring-security-core to 5.5.7 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2022-22976 is resolved across your whole dependency graph.
Workarounds
Constrain what reaches the vulnerable code: limit the size and shape of untrusted input, isolate the affected component in a sandboxed or least-privileged process, and enable the platform's memory-safety mitigations (ASLR, stack protector, hardened allocator) so an out-of-bounds access is more likely to fail closed than to be exploitable.
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 |
|---|---|---|
| OpenShift Developer Tools and Services for OCP 4.11 | jenkins-0:2.401.1.1686831596-3.el8 | RHSA-2023:3663 |
| Red Hat Fuse 7.11 | spring-security | RHSA-2022:5532 |
Frequently Asked Questions
Is CVE-2022-22976 in your dependencies?
Find it across Maven, including transitive dependencies.