Skip to content

Commit

Permalink
🔒 Update to allow for multiple Authentication Providers (#10725)
Browse files Browse the repository at this point in the history
  • Loading branch information
haynescd authored Mar 27, 2024
1 parent 24819c3 commit a2539ae
Showing 1 changed file with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,12 @@ public SecurityFilterChain securityFilterChain(HttpSecurity http, @Nullable Data
}

@Autowired
public void buildAuthenticationManager(AuthenticationManagerBuilder authenticationManagerBuilder, @Nullable AuthenticationProvider tokenAuthenticationProvider) {
if (tokenAuthenticationProvider != null) {
authenticationManagerBuilder.authenticationProvider(tokenAuthenticationProvider);
public void buildAuthenticationManager(AuthenticationManagerBuilder authenticationManagerBuilder,
@Nullable AuthenticationProvider... authenticationProviders) {
if (authenticationProviders != null) {
for (AuthenticationProvider authenticationProvider : authenticationProviders) {
authenticationManagerBuilder.authenticationProvider(authenticationProvider);
}
}
}

Expand Down

0 comments on commit a2539ae

Please sign in to comment.