Skip to content

Commit

Permalink
feat(experimentalIdentityAndAuth): add partial support for `aws.auth#…
Browse files Browse the repository at this point in the history
…sigv4a` (#950)
  • Loading branch information
Steven Yuan authored Sep 19, 2023
1 parent 85448cb commit bec58d0
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,15 @@ public static Map<ShapeId, HttpAuthScheme> getAllEffectiveNoAuthAwareAuthSchemes
effectiveAuthSchemes.put(shapeId, authIndex.getHttpAuthScheme(shapeId));
}
}
// TODO(experimentalIdentityAndAuth): remove after @aws.auth#sigv4a is fully supported
// BEGIN
HttpAuthScheme effectiveSigv4Scheme = effectiveAuthSchemes.get(ShapeId.from("aws.auth#sigv4"));
HttpAuthScheme effectiveSigv4aScheme = effectiveAuthSchemes.get(ShapeId.from("aws.auth#sigv4a"));
HttpAuthScheme supportedSigv4aScheme = authIndex.getHttpAuthScheme(ShapeId.from("aws.auth#sigv4a"));
if (effectiveSigv4Scheme != null && effectiveSigv4aScheme == null && supportedSigv4aScheme != null) {
effectiveAuthSchemes.put(supportedSigv4aScheme.getSchemeId(), supportedSigv4aScheme);
}
// END
return effectiveAuthSchemes;
}
}

0 comments on commit bec58d0

Please sign in to comment.