From a5464ed81959f874100464c0ba7ea95e8c3181cc Mon Sep 17 00:00:00 2001
From: Guillaume Husta
Date: Mon, 28 Nov 2022 15:12:11 +0100
Subject: [PATCH 1/3] Fix typo in DefaultLoginPageConfigurer Javadoc
'isLogoutRequest' seems to have nothing to do here.
---
.../annotation/web/configurers/DefaultLoginPageConfigurer.java | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/config/src/main/java/org/springframework/security/config/annotation/web/configurers/DefaultLoginPageConfigurer.java b/config/src/main/java/org/springframework/security/config/annotation/web/configurers/DefaultLoginPageConfigurer.java
index 95bea02fcf5..2a48bcfc572 100644
--- a/config/src/main/java/org/springframework/security/config/annotation/web/configurers/DefaultLoginPageConfigurer.java
+++ b/config/src/main/java/org/springframework/security/config/annotation/web/configurers/DefaultLoginPageConfigurer.java
@@ -50,7 +50,8 @@
*
* Shared Objects Created
*
- * No shared objects are created. isLogoutRequest
+ * No shared objects are created.
+ *
* Shared Objects Used
*
* The following shared objects are used:
From 626e53d1214b5b6a639648a7c0bd8c44744d50bf Mon Sep 17 00:00:00 2001
From: Sellami <49169744+selllami@users.noreply.github.com>
Date: Tue, 22 Nov 2022 14:59:44 +0100
Subject: [PATCH 2/3] Fix: Replace tenantRepository with tenants
---
.../ROOT/pages/servlet/oauth2/resource-server/multitenancy.adoc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/modules/ROOT/pages/servlet/oauth2/resource-server/multitenancy.adoc b/docs/modules/ROOT/pages/servlet/oauth2/resource-server/multitenancy.adoc
index 8bd734b29d3..8016262f06a 100644
--- a/docs/modules/ROOT/pages/servlet/oauth2/resource-server/multitenancy.adoc
+++ b/docs/modules/ROOT/pages/servlet/oauth2/resource-server/multitenancy.adoc
@@ -248,7 +248,7 @@ public class TenantJWSKeySelector
}
private JWSKeySelector fromTenant(String tenant) {
- return Optional.ofNullable(this.tenantRepository.findById(tenant)) <3>
+ return Optional.ofNullable(this.tenants.findById(tenant)) <3>
.map(t -> t.getAttrbute("jwks_uri"))
.map(this::fromUri)
.orElseThrow(() -> new IllegalArgumentException("unknown tenant"));
From f39f215140ebf042852935a0bc61cccef289fd5e Mon Sep 17 00:00:00 2001
From: Mitja Kotnik
Date: Wed, 23 Nov 2022 20:32:55 +0100
Subject: [PATCH 3/3] Replace javadoc with SecurityFilterChain bean definition
---
.../web/configurers/UrlAuthorizationConfigurer.java | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/config/src/main/java/org/springframework/security/config/annotation/web/configurers/UrlAuthorizationConfigurer.java b/config/src/main/java/org/springframework/security/config/annotation/web/configurers/UrlAuthorizationConfigurer.java
index 0fae7eff10a..85ad311a43d 100644
--- a/config/src/main/java/org/springframework/security/config/annotation/web/configurers/UrlAuthorizationConfigurer.java
+++ b/config/src/main/java/org/springframework/security/config/annotation/web/configurers/UrlAuthorizationConfigurer.java
@@ -49,10 +49,11 @@
*
*
*
- * protected void configure(HttpSecurity http) throws Exception {
- * http.apply(new UrlAuthorizationConfigurer<HttpSecurity>()).getRegistry()
- * .antMatchers("/users**", "/sessions/**").hasRole("USER")
- * .antMatchers("/signup").hasRole("ANONYMOUS").anyRequest().hasRole("USER");
+ * @Bean
+ * public SecurityFilterChain filterChain(HttpSecurity http, ApplicationContext context) throws Exception {
+ * http.apply(new UrlAuthorizationConfigurer<HttpSecurity>(context)).getRegistry()
+ * .requestMatchers("/users**", "/sessions/**").hasRole("USER")
+ * .requestMatchers("/signup").hasRole("ANONYMOUS").anyRequest().hasRole("USER");
* }
*
*