Skip to main content

Find CVE-2026-22732 (Spring Security header suppression)

io.moderne.recipe.cve202622732.FindSpringSecurityHeaderSuppression

Detects code susceptible to CVE-2026-22732, where setting Content-Length via HttpServletResponse.setHeader / setIntHeader / addIntHeader (or the WebFlux equivalents) bypasses Spring Security's OnCommittedResponseWrapper, letting the container commit the response before the lazy header-writing filter runs and silently dropping security headers (X-Frame-Options, X-Content-Type-Options, Cache-Control, etc.). Also emits one data-table row per project recording the resolved Spring Security version.

Recipe source

This recipe is only available to users of Moderne.

This recipe is available under the Moderne Proprietary License.

Usage

This recipe has no required configuration options. Users of Moderne can run it via the Moderne CLI.

You will need to have configured the Moderne CLI on your machine before you can run the following command.

shell
mod run . --recipe FindSpringSecurityHeaderSuppression

If the recipe is not available locally, then you can install it using:

mod config recipes jar install io.moderne.recipe:rewrite-cve-2026-22732:0.3.0

See how this recipe works across multiple open-source repositories

Run this recipe on OSS repos at scale with the Moderne SaaS.

The community edition of the Moderne platform enables you to easily run recipes across thousands of open-source repositories.

Please contact Moderne for more information about safely running the recipes on your own codebase in a private SaaS.

Data Tables

Spring Security version by project

io.moderne.recipe.cve202622732.table.SpringSecurityVersionByProject

One row per project with a detected Spring Security dependency. Customers join this with the taint-flow / direct-commit findings to see the Spring Security version in effect for each hit.

Column NameDescription
ProjectA stable identifier for the project (groupId:artifactId or Gradle project path).
GroupThe dependency groupId (typically org.springframework.security).
ArtifactThe dependency artifactId (e.g. spring-security-web).
VersionThe resolved version string.
AffectedWhether the resolved version falls in a CVE-2026-22732-affected range per the Spring advisory.