Skip to content

Commit

Permalink
feedback fix
Browse files Browse the repository at this point in the history
  • Loading branch information
vvaadd committed May 15, 2024
1 parent 8ba0114 commit 3004b2c
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -50,20 +50,22 @@ DigestAuthenticationEntryPoint authenticationEntryPoint() {
DigestAuthenticationEntryPoint result = new DigestAuthenticationEntryPoint();
result.setRealmName("My App Realm");
result.setKey("3028472b-da34-4501-bfd8-a355c42bdf92");
return result;
}
DigestAuthenticationFilter digestAuthenticationFilter() {
DigestAuthenticationFilter result = new DigestAuthenticationFilter();
result.setUserDetailsService(userDetailsService);
result.setAuthenticationEntryPoint(authenticationEntryPoint());
return result;
}
@Bean
public SecurityFilterChain filterChain(HttpSecurity http) throws Exception {
http
// ...
.exceptionHandling(e -> e.authenticationEntryPoint(authenticationEntryPoint()))
.addFilterAfter(digestAuthenticationFilter(), ExceptionTranslationFilter.class);
.addFilter(digestAuthenticationFilter());
return http.build();
}
----
Expand Down

0 comments on commit 3004b2c

Please sign in to comment.