xii
10/16/2020, 2:16 AMxii
10/16/2020, 2:17 AMI have a typical rest controller, with a preauthorization to verify the user is trying to access his own data
xii
10/16/2020, 2:19 AM@GetMapping(path = ["/test"])
@PreAuthorize("@authenticationService.authForGetOwnData(#userId)")
suspend fun getOwnData(
@RequestParam(value = "user_id", required = true) userId: Long,
@RequestParam(value = "from", required = true) from: Instant,
@RequestParam(value = "to") to: Instant = Instant.now(),
): ownData =
blabla
xii
10/16/2020, 2:20 AMjava.lang.ArrayIndexOutOfBoundsException: Index 3 out of bounds for length 3
at org.springframework.security.access.expression.method.MethodSecurityEvaluationContext.addArgumentsAsVariables(MethodSecurityEvaluationContext.java:115)
Suppressed: reactor.core.publisher.FluxOnAssembly$OnAssemblyException:
xii
10/16/2020, 2:20 AMxii
10/16/2020, 2:20 AMxii
10/16/2020, 2:29 AM@EnableGlobalMethodSecurity(prePostEnabled = true)
xii
10/16/2020, 2:32 AM@EnableReactiveMethodSecurity
i blame staying up too late 🙂xii
10/16/2020, 2:35 AM