diff --git a/config/src/main/java/org/springframework/security/config/annotation/web/configurers/openid/OpenIDLoginConfigurer.java b/config/src/main/java/org/springframework/security/config/annotation/web/configurers/openid/OpenIDLoginConfigurer.java index 604928bcb0..f8fa11a3e2 100644 --- a/config/src/main/java/org/springframework/security/config/annotation/web/configurers/openid/OpenIDLoginConfigurer.java +++ b/config/src/main/java/org/springframework/security/config/annotation/web/configurers/openid/OpenIDLoginConfigurer.java @@ -99,7 +99,7 @@ import org.springframework.security.web.util.matcher.RequestMatcher; *
- * This {@link Authentication} associates an {@link OAuth2User} principal to a + * This {@link Authentication} associates an {@link OAuth2User} principal to an * {@link OAuth2ClientAuthenticationToken} which represents the "Authorized Client". * * @author Joe Grandja diff --git a/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/oidc/client/authentication/OidcClientAuthenticationToken.java b/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/oidc/client/authentication/OidcClientAuthenticationToken.java index 23b01b19f4..173389b583 100644 --- a/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/oidc/client/authentication/OidcClientAuthenticationToken.java +++ b/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/oidc/client/authentication/OidcClientAuthenticationToken.java @@ -23,7 +23,7 @@ import org.springframework.security.oauth2.oidc.core.IdToken; import org.springframework.util.Assert; /** - * A {@link OAuth2ClientAuthenticationToken} that represents an + * An {@link OAuth2ClientAuthenticationToken} that represents an * OpenID Connect 1.0 Client {@link Authentication}. * *
diff --git a/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/oidc/client/authentication/OidcUserAuthenticationToken.java b/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/oidc/client/authentication/OidcUserAuthenticationToken.java index fdf2e4fdf1..c476165fee 100644 --- a/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/oidc/client/authentication/OidcUserAuthenticationToken.java +++ b/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/oidc/client/authentication/OidcUserAuthenticationToken.java @@ -25,11 +25,11 @@ import java.util.Collection; import java.util.Collections; /** - * A {@link OAuth2UserAuthenticationToken} that represents an + * An {@link OAuth2UserAuthenticationToken} that represents an * OpenID Connect 1.0 User {@link Authentication}. * *
- * This {@link Authentication} associates an {@link OidcUser} principal to a
+ * This {@link Authentication} associates an {@link OidcUser} principal to an
* {@link OidcClientAuthenticationToken} which represents the "Authorized Client".
*
* @author Joe Grandja
diff --git a/test/src/main/java/org/springframework/security/test/web/servlet/request/SecurityMockMvcRequestBuilders.java b/test/src/main/java/org/springframework/security/test/web/servlet/request/SecurityMockMvcRequestBuilders.java
index c11fe871c1..6012d899fb 100644
--- a/test/src/main/java/org/springframework/security/test/web/servlet/request/SecurityMockMvcRequestBuilders.java
+++ b/test/src/main/java/org/springframework/security/test/web/servlet/request/SecurityMockMvcRequestBuilders.java
@@ -217,7 +217,7 @@ public final class SecurityMockMvcRequestBuilders {
}
/**
- * Specify a media type to to set as the Accept header in the request.
+ * Specify a media type to set as the Accept header in the request.
*
* @param acceptMediaType the {@link MediaType} to set the Accept header to.
* Default is: MediaType.APPLICATION_FORM_URLENCODED
diff --git a/webflux/src/main/java/org/springframework/security/web/server/DefaultServerRedirectStrategy.java b/webflux/src/main/java/org/springframework/security/web/server/DefaultServerRedirectStrategy.java
index 4d78bd03ff..094b545780 100644
--- a/webflux/src/main/java/org/springframework/security/web/server/DefaultServerRedirectStrategy.java
+++ b/webflux/src/main/java/org/springframework/security/web/server/DefaultServerRedirectStrategy.java
@@ -63,7 +63,7 @@ public class DefaultServerRedirectStrategy implements ServerRedirectStrategy {
/**
* Sets if the location is relative to the context.
* @param contextRelative if redirects should be relative to the context.
- Default is true.
+ * Default is true.
*/
public void setContextRelative(boolean contextRelative) {
this.contextRelative = contextRelative;
diff --git a/webflux/src/main/java/org/springframework/security/web/server/authentication/RedirectServerAuthenticationSuccessHandler.java b/webflux/src/main/java/org/springframework/security/web/server/authentication/RedirectServerAuthenticationSuccessHandler.java
index 9a54ae3810..3d29c8ce87 100644
--- a/webflux/src/main/java/org/springframework/security/web/server/authentication/RedirectServerAuthenticationSuccessHandler.java
+++ b/webflux/src/main/java/org/springframework/security/web/server/authentication/RedirectServerAuthenticationSuccessHandler.java
@@ -50,7 +50,7 @@ public class RedirectServerAuthenticationSuccessHandler
}
/**
- * Where the user is redirected to upon AuthenticationSuccess
+ * Where the user is redirected to upon authentication success
* @param location the location to redirect to. The default is "/"
*/
public void setLocation(URI location) {
diff --git a/webflux/src/test/java/org/springframework/security/web/server/DefaultServerRedirectStrategyTests.java b/webflux/src/test/java/org/springframework/security/web/server/DefaultServerRedirectStrategyTests.java
index b8f4008a30..4bf65714b2 100644
--- a/webflux/src/test/java/org/springframework/security/web/server/DefaultServerRedirectStrategyTests.java
+++ b/webflux/src/test/java/org/springframework/security/web/server/DefaultServerRedirectStrategyTests.java
@@ -23,8 +23,6 @@ import org.mockito.junit.MockitoJUnitRunner;
import org.springframework.http.HttpStatus;
import org.springframework.mock.http.server.reactive.MockServerHttpRequest;
import org.springframework.mock.web.server.MockServerWebExchange;
-import org.springframework.security.authentication.AuthenticationCredentialsNotFoundException;
-import org.springframework.security.core.AuthenticationException;
import org.springframework.web.server.ServerWebExchange;
import java.net.URI;
@@ -47,16 +45,14 @@ public class DefaultServerRedirectStrategyTests {
private DefaultServerRedirectStrategy strategy =
new DefaultServerRedirectStrategy();
- private AuthenticationException exception = new AuthenticationCredentialsNotFoundException("Authentication Required");
-
@Test(expected = IllegalArgumentException.class)
public void sendRedirectWhenLocationNullThenException() {
- this.strategy.sendRedirect(this.exchange, (URI) null);
+ this.strategy.sendRedirect(this.exchange, null);
}
@Test(expected = IllegalArgumentException.class)
public void sendRedirectWhenExchangeNullThenException() {
- this.strategy.sendRedirect((ServerWebExchange) null, this.location);
+ this.strategy.sendRedirect(null, this.location);
}
@Test
@@ -67,7 +63,7 @@ public class DefaultServerRedirectStrategyTests {
}
@Test
- public void sendRedirectWhenNoContextThenStatusAndLocationSet() {
+ public void sendRedirectWhenNoContextPathThenStatusAndLocationSet() {
this.exchange = exchange(MockServerHttpRequest.get("/"));
this.strategy.sendRedirect(this.exchange, this.location).block();
@@ -122,7 +118,7 @@ public class DefaultServerRedirectStrategyTests {
}
@Test(expected = IllegalArgumentException.class)
- public void setHttpStatusWhenNullLocationThenException() {
+ public void setHttpStatusWhenNullThenException() {
this.strategy.setHttpStatus(null);
}
diff --git a/webflux/src/test/java/org/springframework/security/web/server/DelegatingServerAuthenticationEntryPointTests.java b/webflux/src/test/java/org/springframework/security/web/server/DelegatingServerAuthenticationEntryPointTests.java
index d215bda6c0..9845d4d620 100644
--- a/webflux/src/test/java/org/springframework/security/web/server/DelegatingServerAuthenticationEntryPointTests.java
+++ b/webflux/src/test/java/org/springframework/security/web/server/DelegatingServerAuthenticationEntryPointTests.java
@@ -70,7 +70,6 @@ public class DelegatingServerAuthenticationEntryPointTests {
Mono