Skip to content

Commit

Permalink
Use ExtensionsManager.lookupExtensionSettingsById when verifying exte…
Browse files Browse the repository at this point in the history
…nsion unique id (opensearch-project#2749) (opensearch-project#2755)

Signed-off-by: Craig Perkins <[email protected]>
(cherry picked from commit 9d758f9)

Co-authored-by: Craig Perkins <[email protected]>
  • Loading branch information
2 people authored and stephen-crawford committed May 16, 2023
1 parent 8514549 commit c53a7a9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ protected void addAdditionalContextValues(final String action, final TransportRe
String extensionUniqueId = getThreadContext().getHeader("extension_unique_id");
if (extensionUniqueId != null) {
ExtensionsManager extManager = OpenSearchSecurityPlugin.GuiceHolder.getExtensionsManager();
if (extManager.getExtensionIdMap().containsKey(extensionUniqueId)) {
if (extManager.lookupExtensionSettingsById(extensionUniqueId).isPresent()) {
getThreadContext().putTransient(ConfigConstants.OPENDISTRO_SECURITY_SSL_TRANSPORT_EXTENSION_REQUEST, Boolean.TRUE);
}
}
Expand Down

0 comments on commit c53a7a9

Please sign in to comment.