CVE-2025-22228
published 2025-03-20CVE-2025-22228: BCryptPasswordEncoder.matches(CharSequence,String) will incorrectly return true for passwords larger than 72 characters as long as the first 72 characters are…
PriorityP341high7.4CVSS 3.1
AVNACHPRNUINSUCHIHAN
EPSS
0.57%
43.4th percentile
BCryptPasswordEncoder.matches(CharSequence,String) will incorrectly return true for passwords larger than 72 characters as long as the first 72 characters are the same.
Affected
7 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| spring | spring_security | — | — |
| spring | spring_security | — | — |
| spring | spring_security | — | — |
| spring | spring_security | — | — |
| spring | spring_security | — | — |
| spring | spring_security | — | — |
| spring | spring_security | — | — |
CVSS provenance
nvdv3.17.4HIGHCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
ghsa7.4HIGH
osv7.4HIGH
vendor_oracle7.4HIGH
vendor_redhat7.4HIGH
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
OSV
Spring Security has a broken timing attack mitigation implemented in DaoAuthenticationProvide
osv·2026-01-22·CVSS 7.4
CVE-2025-22234 [HIGH] Spring Security has a broken timing attack mitigation implemented in DaoAuthenticationProvide
Spring Security has a broken timing attack mitigation implemented in DaoAuthenticationProvide
The fix applied in CVE-2025-22228 inadvertently broke the timing attack mitigation implemented in DaoAuthenticationProvider. This can allow attackers to infer valid usernames or other authentication behavior via response-time differences under certain configurations.
GHSA
Spring Security has a broken timing attack mitigation implemented in DaoAuthenticationProvide
ghsa·2026-01-22·CVSS 7.4
CVE-2025-22234 [HIGH] CWE-208 Spring Security has a broken timing attack mitigation implemented in DaoAuthenticationProvide
Spring Security has a broken timing attack mitigation implemented in DaoAuthenticationProvide
The fix applied in CVE-2025-22228 inadvertently broke the timing attack mitigation implemented in DaoAuthenticationProvider. This can allow attackers to infer valid usernames or other authentication behavior via response-time differences under certain configurations.
GHSA
Spring Security Does Not Enforce Password Length
ghsa·2025-03-20
CVE-2025-22228 [HIGH] CWE-287 Spring Security Does Not Enforce Password Length
Spring Security Does Not Enforce Password Length
BCryptPasswordEncoder.matches(CharSequence,String) will incorrectly return true for passwords larger than 72 characters as long as the first 72 characters are the same.
OSV
Spring Security Does Not Enforce Password Length
osv·2025-03-20
CVE-2025-22228 [HIGH] Spring Security Does Not Enforce Password Length
Spring Security Does Not Enforce Password Length
BCryptPasswordEncoder.matches(CharSequence,String) will incorrectly return true for passwords larger than 72 characters as long as the first 72 characters are the same.
Red Hat
org.springframework.security/spring-security-core: Spring Security - BCrypt Password Encoder maximum password length breaks timing attack mitigation
vendor_redhat·2026-01-22·CVSS 7.4
CVE-2025-22234 [HIGH] CWE-208 org.springframework.security/spring-security-core: Spring Security - BCrypt Password Encoder maximum password length breaks timing attack mitigation
org.springframework.security/spring-security-core: Spring Security - BCrypt Password Encoder maximum password length breaks timing attack mitigation
The fix applied in CVE-2025-22228 inadvertently broke the timing attack mitigation implemented in DaoAuthenticationProvider. This can allow attackers to infer valid usernames or other authentication behavior via response-time differences under certain configurations.
A timing weakness has been discovered in the Spring Framework security core package. The fix applied for CVE-2025-22228 inadvertently broke the timing attack mitigation implemented in DaoAuthenticationProvider. This can allow attackers to infer valid usernames or other authentication behavior via response-time differences under certain configurations.
Mitigation: Mitigation for
Oracle
Oracle Oracle Financial Services Applications Risk Matrix: Common Core (Spring Security) — CVE-2025-22228
vendor_oracle·2026-01-15·CVSS 7.4
CVE-2025-22228 [HIGH] Oracle Oracle Financial Services Applications Risk Matrix: Common Core (Spring Security) — CVE-2025-22228
Oracle Oracle Financial Services Applications Risk Matrix: Common Core (Spring Security) vulnerability
CVE: CVE-2025-22228
CVSS: 7.4
Protocol: HTTP
Remote exploit: Yes
Affected versions: Network
Advisory: cpujan2026 (JAN 2026)
Red Hat
spring-security-core: Spring Security BCryptPasswordEncoder does not enforce maximum password length
vendor_redhat·2025-03-20·CVSS 7.4
CVE-2025-22228 [HIGH] CWE-863 spring-security-core: Spring Security BCryptPasswordEncoder does not enforce maximum password length
spring-security-core: Spring Security BCryptPasswordEncoder does not enforce maximum password length
BCryptPasswordEncoder.matches(CharSequence,String) will incorrectly return true for passwords larger than 72 characters as long as the first 72 characters are the same.
A flaw was found in the spring-security-core password encoder. This vulnerability allows incorrect password matching via input manipulation.
Mitigation: Red Hat Product Security does not have a recommended mitigation at this time.
Package: spring-security-core (A-MQ Clients 2) - Out of support scope
Package: quarkus-bom (Red Hat build of Quarkus) - Not affected
Package: spring-security-core (Red Hat Data Grid 8) - Will not fix
Package: org.apache.servicemix.bundles.spring-security-core (Red Hat Fuse 7) - Will not fix
No detection rules found.
No public exploits indexed.
Wiz
CVE-2025-22234 Impact, Exploitability, and Mitigation Steps | Wiz
blogs_wiz·CVSS 3.7
CVE-2025-22234 [LOW] CVE-2025-22234 Impact, Exploitability, and Mitigation Steps | Wiz
## CVE-2025-22234 :
Jenkins vulnerability analysis and mitigation
The fix applied in CVE-2025-22228 inadvertently broke the timing attack mitigation implemented in DaoAuthenticationProvider. This can allow attackers to infer valid usernames or other authentication behavior via response-time differences under certain configurations.
Source : NVD
## 5.3
Score
Published January 22, 2026
Severity MEDIUM
CNA Score 5.3
Affected Technologies
Jenkins
Spring Security
Has Public Exploit Yes
Has CISA KEV Exploit No
CISA KEV Release Date N/A
CISA KEV Due Date N/A
Exploitation Probability Percentile (EPSS) 1.4
Exploitation Probability (EPSS) N/A
Affected packages and libraries
org.springframework.security:spring-security-core
jenkins
Sources
NVD
Maven Severity MEDIUM Has Fix Ad
Bugzilla
CVE-2025-22228 spring-security-core: Spring Security BCryptPasswordEncoder does not enforce maximum password length
bugzilla·2025-03-20·CVSS 7.4
CVE-2025-22228 [HIGH] CVE-2025-22228 spring-security-core: Spring Security BCryptPasswordEncoder does not enforce maximum password length
CVE-2025-22228 spring-security-core: Spring Security BCryptPasswordEncoder does not enforce maximum password length
BCryptPasswordEncoder.matches(CharSequence,String) will incorrectly return true for passwords larger than 72 characters as long as the first 72 characters are the same.
Discussion:
This issue has been addressed in the following products:
Red Hat build of Apache Camel 4.8.5 for Spring Boot
Via RHSA-2025:3543 https://access.redhat.com/errata/RHSA-2025:3543
---
This issue has been addressed in the following products:
OCP-Tools-4.18-RHEL-9
Via RHSA-2025:10092 https://access.redhat.com/errata/RHSA-2025:10092
---
This issue has been addressed in the following products:
OCP-Tools-4.17-RHEL-9
Via RHSA-2025:10097 https://access.redhat.com/errata/RHSA-2025:10097
---
This
2025-03-20
Published