Latest in branch 5.6
5.6.12
Released 17 Jul 2023
(2 years ago)
SoftwareSpring Security
Branch5.6
Supported
Java/Jakarta EE
Java 8+
Servlet 3.0+
Initial release5.6.0
15 Nov 2021
(4 years ago)
Latest release5.6.12
17 Jul 2023
(2 years ago)
End of
OSS support
30 Nov 2022
(Ended 3 years, 5 months ago)
End of
enterprise support
29 Feb 2024
(Ended 2 years, 2 months ago)
Release noteshttps://github.com/spring-projects/spring-security/releases/tag/5.6.12
Source codehttps://github.com/spring-projects/spring-security/tree/5.6.12
Downloadhttps://github.com/spring-projects/spring-security/releases/tag/5.6.12
Spring Security 5.6 ReleasesView full list

What Is New in Spring Security 5.6

Category Highlights
New Features Revamped OAuth 2.0 reactive documentation, SAML 2.0 logout request now includes KeyInfo, clearer MissingCsrfTokenException message, OAuth2 Resource Server retry fix for multi-tenant setups, DaoAuthenticationProviderTests avg function now returns fractions.
Improvements Dependency upgrades: aspectj-plugin 6.2.0, Nimbus 9.19, Hibernate 5.6.1.Final, HSQLDB 2.6.1, Reactor 2020.0.13, Logback 1.2.7, Spring Framework 5.3.13, Reactor Netty 1.0.13.
Bug Fixes Added KeyInfo section to LogoutRequest, fixed missing KeyInfo in SAML 2.0 logout, OAuth2 Resource Server no longer skips retry on first failure in multi-tenant mode, corrected missing port documentation, ensured SAML 2.0 JUnit tests run, silenced various Javadoc warnings.

How does Spring Security 5.6 improve OAuth 2.0 reactive documentation?

Spring Security 5.6 delivers a complete revamp of the OAuth 2.0 login and client documentation for reactive applications, making it easier to configure and troubleshoot.

  • Separate sections for login flow, client registration, and token handling.
  • Step-by-step code snippets that use ServerHttpSecurity and ReactiveOAuth2Client APIs.
  • New diagrams illustrate the interaction between the resource server, authorization server, and the reactive client.
http
    .oauth2Login()
        .authorizationEndpoint()
            .baseUri("/oauth2/authorize")
        .and()
    .oauth2Client();

What changes were made to SAML 2.0 logout handling in Spring Security 5.6?

SAML 2.0 logout requests now include a KeyInfo element on the RP side, satisfying stricter IdP requirements.

  • The LogoutRequest builder automatically adds a KeyInfo section when a signing key is configured.
  • Existing logout flows continue to work; only IdPs that previously rejected unsigned requests benefit.
  • Unit tests for SAML 2.0 now cover the new element, preventing regressions.
LogoutRequest logoutRequest = Saml2LogoutRequest
    .withRelyingPartyRegistration(registration)
    .logoutUrl("https://idp.example.com/logout")
    .build();

How does Spring Security 5.6 address multi-tenant OAuth2 Resource Server retry behavior?

The resource server now retries the token introspection request on the first failure when operating in a multi-tenant environment.

  • This prevents 401 responses caused by transient network glitches between tenants.
  • The retry logic is scoped per tenant, preserving isolation.
  • Configuration remains unchanged; the behavior is enabled by default.

What improvements were made to the MissingCsrfTokenException message in Spring Security 5.6?

The exception message now accurately reflects scenarios where CSRF tokens are not stored in the HTTP session.

  • When CsrfTokenRepository is stateless (e.g., cookie-based), the message no longer mentions a missing session.
  • This reduces confusion during debugging of API clients that rely on header-only CSRF handling.

Frequently Asked Questions

Do I need to modify my existing OAuth2 login configuration when upgrading to Spring Security 5.6?
Most configurations work unchanged unless you rely on the old reactive documentation examples.

How can I enable the new KeyInfo section in a SAML2 LogoutRequest?
Add a signing key to the RelyingPartyRegistration and the framework will include KeyInfo automatically.

Which version of Spring Framework is bundled with Spring Security 5.6?
Spring Framework 5.3.13.

What is the recommended way to upgrade the Nimbus JOSE JWT library after moving to 5.6?
Update the Maven dependency to com.nimbusds:nimbus-jose-jwt version 9.19.

Are there any breaking changes to DaoAuthenticationProvider in 5.6?
No breaking changes; only a test fix for the avg function.

Where can I find the updated reactive OAuth2 documentation?
In the official Spring Security reference guide under the Reactive OAuth2 Login section.

Releases In Branch 5.6

VersionRelease date
5.6.1217 Jul 2023
(2 years ago)
5.6.1119 Jun 2023
(2 years ago)
5.6.1019 Dec 2022
(3 years ago)
5.6.931 Oct 2022
(3 years ago)
5.6.817 Oct 2022
(3 years ago)
5.6.715 Aug 2022
(3 years ago)
5.6.620 Jun 2022
(3 years ago)
5.6.518 May 2022
(4 years ago)
5.6.416 May 2022
(4 years ago)
5.6.318 Apr 2022
(4 years ago)
5.6.221 Feb 2022
(4 years ago)
5.6.120 Dec 2021
(4 years ago)
5.6.015 Nov 2021
(4 years ago)
5.6.0-RC118 Oct 2021
(4 years ago)
5.6.0-M320 Sep 2021
(4 years ago)
5.6.0-M216 Aug 2021
(4 years ago)
5.6.0-M119 Jul 2021
(4 years ago)