Closed xunterr closed 1 year ago
Hello, I am trying to set up exception handling for spring security. As it says in the documentation, setting up the UnauthorizedEntryPoint:
@Bean public UnauthorizedEntryPoint unauthorizedEntryPoint( HttpStatusMapper httpStatusMapper, ErrorCodeMapper errorCodeMapper, ErrorMessageMapper errorMessageMapper, ObjectMapper objectMapper) { return new UnauthorizedEntryPoint(httpStatusMapper, errorCodeMapper, errorMessageMapper, objectMapper); } @Bean public SecurityFilterChain securityFilterChain(HttpSecurity http, UnauthorizedEntryPoint unauthorizedEntryPoint) throws Exception{ http //... .exceptionHandling().authenticationEntryPoint(unauthorizedEntryPoint); return http.build(); }
But content type is not a json. Response:
Found the problem. Will be fixed in an upcoming release.
https://github.com/wimdeblauwe/error-handling-spring-boot-starter/releases/tag/4.1.2
Hello, I am trying to set up exception handling for spring security. As it says in the documentation, setting up the UnauthorizedEntryPoint:
But content type is not a json. Response: