Skip to content

Commit

Permalink
bug fix for api key authenticator
Browse files Browse the repository at this point in the history
  • Loading branch information
DDH13 committed Mar 20, 2024
1 parent 1476954 commit 79ec74c
Showing 1 changed file with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -209,9 +209,12 @@ private AuthenticationContext processAPIKey(RequestContext requestContext, Strin
APIKeyValidationInfoDTO validationInfoDto;
log.debug("Validating subscription for API Key against subscription store."
+ " context: {} version: {}", apiContext, apiVersion);
validationInfoDto = KeyValidator.validateSubscription(apiUuid, apiContext,
requestContext.getMatchedAPI(), payload);
if (!requestContext.getMatchedAPI().isSystemAPI()) {
boolean isGatewayLevelSubscriptionValidationEnabled = ConfigHolder.getInstance().getConfig()
.getMandateSubscriptionValidation();
if (!requestContext.getMatchedAPI().isSystemAPI() && (isGatewayLevelSubscriptionValidationEnabled || requestContext.getMatchedAPI()
.isSubscriptionValidation())) {
// validationInfoDto = KeyValidator.validateSubscription(apiUuid, apiContext,
// requestContext.getMatchedAPI(), payload);
log.debug("Validating subscription for API Key using JWT claims against invoked API info."
+ " context: {} version: {}", apiContext, apiVersion);
validationInfoDto = getAPIKeyValidationDTO(requestContext, payload);
Expand Down

0 comments on commit 79ec74c

Please sign in to comment.