Cors issue when redirecting to external auth after logout in Spring Security

Have you tried the OidcClientInitiatedLogoutSuccessHandler provided by Spring Security instead of creating the url directly? It is specifically for the RP-initiated logout. It may give you a slightly different redirect request.

If you’re still having issues, it may also be helpful to include the request/response data from the request itself in the browser.