org.springframework.security:spring-security-config@5.8.2 vulnerabilities

Direct Vulnerabilities

Known vulnerabilities in the org.springframework.security:spring-security-config package. This does not include vulnerabilities belonging to this package’s dependencies.

Automatically find and fix vulnerabilities affecting your projects. Snyk scans for vulnerabilities and provides fixes for free.
Fix for free
Vulnerability Vulnerable Version
  • M
Authorization Bypass

org.springframework.security:spring-security-config is a security configuration package for Spring Framework.

Affected versions of this package are vulnerable to Authorization Bypass due to the use of String.toLowerCase() and String.toUpperCase() that have Locale dependent exceptions, which results in authorization rules not working properly.

How to fix Authorization Bypass?

Upgrade org.springframework.security:spring-security-config to version 5.7.14, 5.8.16, 6.2.8, 6.3.5 or higher.

[,5.7.14) [5.8.0,5.8.16) [6.2.0,6.2.8) [6.3.0,6.3.5)
  • C
Access Control Bypass

org.springframework.security:spring-security-config is a security configuration package for Spring Framework.

Affected versions of this package are vulnerable to Access Control Bypass. When using ** as a pattern in Spring Security configuration for WebFlux a mismatch in pattern matching is created between Spring Security and Spring WebFlux, resulting in a security bypass.

Note:

The fixed versions require Spring Framework versions:

  1. 6.0.11+

  2. 5.3.29+

  3. 5.2.25+

Note: The Spring security team have published information about an existing PoC, but have not shared the PoC itself publicly, therefore we don't currently have the ability to verify it.

How to fix Access Control Bypass?

Upgrade org.springframework.security:spring-security-config to version 5.6.12, 5.7.10, 5.8.5, 6.0.5, 6.1.2 or higher.

[5.6.0,5.6.12) [5.7.0,5.7.10) [5.8.0,5.8.5) [6.0.0,6.0.5) [6.1.0,6.1.2)
  • H
Improper Authorization

org.springframework.security:spring-security-config is a security configuration package for Spring Framework.

Affected versions of this package are vulnerable to Improper Authorization due to improper validation in the requestMatchers, leading to authorization rule misconfiguration when the application uses requestMatchers(String) and multiple servlets, one of them being Spring MVC’s DispatcherServlet.

Notes:

An application is only vulnerable when all of the following are true:

  1. Spring MVC is on the classpath.

  2. Spring Security is securing more than one servlet in a single application (one of them being Spring MVC’s DispatcherServlet).

  3. The application uses requestMatchers(String) to refer to endpoints that are not Spring MVC endpoints.

How to fix Improper Authorization?

Upgrade org.springframework.security:spring-security-config to version 5.8.5, 6.0.5, 6.1.2 or higher.

[5.8.0,5.8.5) [6.0.0,6.0.5) [6.1.0,6.1.2)
  • M
Session Fixation

org.springframework.security:spring-security-config is a security configuration package for Spring Framework.

Affected versions of this package are vulnerable to Session Fixation due to the logout functionality not properly clearing the security context when using serialized versions. Additionally, it is not possible to explicitly save an empty security context to the HttpSessionSecurityContextRepository. This allows users to stay authenticated after a logout.

NOTE: Applications are only vulnerable if any of the following conditions are true:

  • The SecurityContextHolderFilter or requireExplicitSave(true) is in use with logout support for serialized sessions, and invalidateHttpSession(false).

  • Users are logged out manually by saving an empty SecurityContext into the HttpSessionSecurityContextRepository.

  • A custom SecurityContextRepository is in use that does not rely on the HttpSession.

How to fix Session Fixation?

Upgrade org.springframework.security:spring-security-config to version 5.7.8, 5.8.3, 6.0.3 or higher.

[5.7.0,5.7.8) [5.8.0,5.8.3) [6.0.0,6.0.3)