|
|
|
|
@ -60,7 +60,7 @@ class OAuth2LoginSecurityConfig {
@@ -60,7 +60,7 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
fun securityWebFilterChain(http: ServerHttpSecurity): SecurityWebFilterChain { |
|
|
|
|
http { |
|
|
|
|
return http { |
|
|
|
|
oauth2Login { |
|
|
|
|
authenticationConverter = authenticationConverter() |
|
|
|
|
authenticationMatcher = authenticationMatcher() |
|
|
|
|
@ -75,8 +75,6 @@ class OAuth2LoginSecurityConfig {
@@ -75,8 +75,6 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
securityContextRepository = securityContextRepository() |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return http.build() |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
---- |
|
|
|
|
@ -158,7 +156,7 @@ class OAuth2LoginSecurityConfig {
@@ -158,7 +156,7 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
fun securityWebFilterChain(http: ServerHttpSecurity): SecurityWebFilterChain { |
|
|
|
|
http { |
|
|
|
|
return http { |
|
|
|
|
exceptionHandling { |
|
|
|
|
authenticationEntryPoint = RedirectServerAuthenticationEntryPoint("/login/oauth2") |
|
|
|
|
} |
|
|
|
|
@ -166,8 +164,6 @@ class OAuth2LoginSecurityConfig {
@@ -166,8 +164,6 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
authorizationRequestResolver = authorizationRequestResolver() |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return http.build() |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private fun authorizationRequestResolver(): ServerOAuth2AuthorizationRequestResolver { |
|
|
|
|
@ -243,13 +239,11 @@ class OAuth2LoginSecurityConfig {
@@ -243,13 +239,11 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
fun securityWebFilterChain(http: ServerHttpSecurity): SecurityWebFilterChain { |
|
|
|
|
http { |
|
|
|
|
return http { |
|
|
|
|
oauth2Login { |
|
|
|
|
authenticationMatcher = PathPatternParserServerWebExchangeMatcher("/login/oauth2/callback/{registrationId}") |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return http.build() |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
---- |
|
|
|
|
@ -369,11 +363,9 @@ class OAuth2LoginSecurityConfig {
@@ -369,11 +363,9 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
fun securityWebFilterChain(http: ServerHttpSecurity): SecurityWebFilterChain { |
|
|
|
|
http { |
|
|
|
|
return http { |
|
|
|
|
oauth2Login { } |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return http.build() |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
@ -458,11 +450,9 @@ class OAuth2LoginSecurityConfig {
@@ -458,11 +450,9 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
fun securityWebFilterChain(http: ServerHttpSecurity): SecurityWebFilterChain { |
|
|
|
|
http { |
|
|
|
|
return http { |
|
|
|
|
oauth2Login { } |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return http.build() |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
@ -536,11 +526,9 @@ class OAuth2LoginSecurityConfig {
@@ -536,11 +526,9 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
fun securityWebFilterChain(http: ServerHttpSecurity): SecurityWebFilterChain { |
|
|
|
|
http { |
|
|
|
|
return http { |
|
|
|
|
oauth2Login { } |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return http.build() |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
@ -594,11 +582,9 @@ class OAuth2LoginSecurityConfig {
@@ -594,11 +582,9 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
fun securityWebFilterChain(http: ServerHttpSecurity): SecurityWebFilterChain { |
|
|
|
|
http { |
|
|
|
|
return http { |
|
|
|
|
oauth2Login { } |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return http.build() |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
@ -730,7 +716,7 @@ class OAuth2LoginSecurityConfig {
@@ -730,7 +716,7 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
|
|
|
|
|
@Bean |
|
|
|
|
fun securityWebFilterChain(http: ServerHttpSecurity): SecurityWebFilterChain { |
|
|
|
|
http { |
|
|
|
|
return http { |
|
|
|
|
authorizeExchange { |
|
|
|
|
authorize(anyExchange, authenticated) |
|
|
|
|
} |
|
|
|
|
@ -739,8 +725,6 @@ class OAuth2LoginSecurityConfig {
@@ -739,8 +725,6 @@ class OAuth2LoginSecurityConfig {
|
|
|
|
|
logoutSuccessHandler = oidcLogoutSuccessHandler() |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return http.build() |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private fun oidcLogoutSuccessHandler(): ServerLogoutSuccessHandler { |
|
|
|
|
|