Skip to content

Commit 812d96e

Browse files
committed
formatting
1 parent f1126a0 commit 812d96e

File tree

3 files changed

+13
-12
lines changed

3 files changed

+13
-12
lines changed

gateway/pom.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -253,11 +253,11 @@
253253
</build>
254254
</profile>
255255
<profile>
256-
<id>docker-debug</id>
257-
<properties>
258-
<spring-boot.build-image.builder>paketobuildpacks/builder-jammy-base</spring-boot.build-image.builder>
259-
<spring-boot.build-image.imageName>georchestra/gateway:${imageTag}-debug</spring-boot.build-image.imageName>
260-
</properties>
256+
<id>docker-debug</id>
257+
<properties>
258+
<spring-boot.build-image.builder>paketobuildpacks/builder-jammy-base</spring-boot.build-image.builder>
259+
<spring-boot.build-image.imageName>georchestra/gateway:${imageTag}-debug</spring-boot.build-image.imageName>
260+
</properties>
261261
</profile>
262262
<profile>
263263
<id>debianPackage</id>

gateway/src/main/java/org/georchestra/gateway/app/LoginLogoutController.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -197,10 +197,8 @@ private void setHeaderAttributes(Model model) {
197197
/**
198198
* Checks if a given URL is in the safe redirect allow list.
199199
*
200-
* Example gateway.yaml:
201-
* loginRedirectAllowList: >
202-
* http://localhost:8080/geoserver/,
203-
* http://localhost:8080/console/
200+
* Example gateway.yaml: loginRedirectAllowList: >
201+
* http://localhost:8080/geoserver/, http://localhost:8080/console/
204202
*
205203
* @param url the URL to check
206204
* @return {@code true} if the URL is allowed for redirection, {@code false}

gateway/src/main/java/org/georchestra/gateway/filter/global/LoginParamRedirectGatewayFilterFactory.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,8 @@ public class LoginParamRedirectGatewayFilterFactory extends AbstractGatewayFilte
8383
@Override
8484
public LoginParamRedirectGatewayFilter apply(Object config) {
8585
if (redirectServerAuthenticationEntryPoint == null) {
86-
throw new IllegalStateException("redirectServerAuthenticationEntryPoint must be set before using this filter");
86+
throw new IllegalStateException(
87+
"redirectServerAuthenticationEntryPoint must be set before using this filter");
8788
}
8889
return new LoginParamRedirectGatewayFilter(redirectServerAuthenticationEntryPoint);
8990
}
@@ -146,10 +147,12 @@ private Mono<Void> redirectToLoginIfNotAuthenticated(ServerWebExchange exchange,
146147
.flatMap(authentication -> {
147148
if (authentication instanceof AnonymousAuthenticationToken) {
148149
log.info("Redirecting to /login: {}", exchange.getRequest().getURI());
149-
//AuthenticationException isn't used in RedirectServerAuthenticationEntryPoint implementation,
150+
// AuthenticationException isn't used in RedirectServerAuthenticationEntryPoint
151+
// implementation,
150152
// but is required by the method signature
151153
return redirectServerAuthenticationEntryPoint.commence(exchange,
152-
new AuthenticationException("Not applicable") {});
154+
new AuthenticationException("Not applicable") {
155+
});
153156
}
154157
log.info("Already authenticated ({}), proceeding without redirection to /login",
155158
authentication.getName());

0 commit comments

Comments
 (0)