Skip to content

Commit eddbfa5

Browse files
committed
🔧 add new sec rule to backend: allow /public/** endpoints to be used unauthorized
1 parent 1bf1108 commit eddbfa5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

personalization-service/src/main/java/de/muenchen/dbs/personalization/configuration/SecurityConfiguration.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,8 @@ public SecurityFilterChain filterChain(final HttpSecurity http) throws Exception
5252
// allow access to swagger-ui
5353
PathPatternRequestMatcher.withDefaults().matcher(HttpMethod.GET, "/swagger-ui/**"),
5454
// allow access to /actuator/metrics for Prometheus monitoring in OpenShift
55-
PathPatternRequestMatcher.withDefaults().matcher(HttpMethod.GET, "/actuator/metrics"))
55+
PathPatternRequestMatcher.withDefaults().matcher(HttpMethod.GET, "/actuator/metrics"),
56+
PathPatternRequestMatcher.withDefaults().matcher(HttpMethod.GET, "/public/**"))
5657
.permitAll())
5758
.authorizeHttpRequests((requests) -> requests.requestMatchers("/**")
5859
.authenticated())

0 commit comments

Comments
 (0)