Skip to content

Commit

Permalink
Merge branch 'release/6.0.3'
Browse files Browse the repository at this point in the history
  • Loading branch information
sbearcsiro committed Jun 5, 2023
2 parents 6c95e2c + 1f0b1ec commit 463d3bc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package au.org.ala.ws.security;

import au.org.ala.userdetails.UserDetailsClient;
import au.org.ala.ws.security.authenticator.AlaApiKeyAuthenticator;
import au.org.ala.ws.security.authenticator.AlaIpWhitelistAuthenticator;
import au.org.ala.ws.security.authenticator.AlaOidcAuthenticator;
Expand Down Expand Up @@ -167,14 +168,15 @@ public AlaOidcClient getAlaOidcClient(OidcConfiguration oidcConfiguration, JWKSo
@Bean
@ConditionalOnMissingBean
@ConditionalOnProperty(prefix = "security.apikey", name = "enabled")
public AlaApiKeyClient getAlaApiKeyClient(ApiKeyClient apiKeyClient) {
public AlaApiKeyClient getAlaApiKeyClient(ApiKeyClient apiKeyClient, UserDetailsClient userDetailsClient) {

AlaApiKeyCredentialsExtractor credentialsExtractor = new AlaApiKeyCredentialsExtractor();
credentialsExtractor.setHeaderName(apiKeyProperties.getHeader().getOverride());
credentialsExtractor.setAlternativeHeaderNames(apiKeyProperties.getHeader().getAlternatives());

AlaApiKeyAuthenticator authenticator = new AlaApiKeyAuthenticator();
authenticator.setApiKeyClient(apiKeyClient);
authenticator.setUserDetailsClient(userDetailsClient);

return new AlaApiKeyClient(credentialsExtractor, authenticator);
}
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
projectVersion=6.0.2
projectVersion=6.0.3

org.gradle.daemon=true
org.gradle.parallel=true
Expand Down

0 comments on commit 463d3bc

Please sign in to comment.