Skip to content

Commit

Permalink
Change the name into keyUtils with the s
Browse files Browse the repository at this point in the history
Signed-off-by: Ryan Liang <[email protected]>
  • Loading branch information
RyanL1997 committed Aug 22, 2023
1 parent dae0ac7 commit 2349213
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
import org.opensearch.core.rest.RestStatus;
import org.opensearch.security.auth.HTTPAuthenticator;
import org.opensearch.security.user.AuthCredentials;
import org.opensearch.security.util.keyUtil;
import org.opensearch.security.util.keyUtils;

public class HTTPJwtAuthenticator implements HTTPAuthenticator {

Expand All @@ -57,7 +57,7 @@ public HTTPJwtAuthenticator(final Settings settings, final Path configPath) {
super();

String signingKey = settings.get("signing_key");
JwtParser _jwtParser = keyUtil.createJwtParserFromSigningKey(signingKey, log);
JwtParser _jwtParser = keyUtils.createJwtParserFromSigningKey(signingKey, log);

jwtUrlParameter = settings.get("jwt_url_parameter");
jwtHeaderName = settings.get("jwt_header", HttpHeaders.AUTHORIZATION);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
import org.opensearch.security.authtoken.jwt.EncryptionDecryptionUtil;
import org.opensearch.security.ssl.util.ExceptionUtils;
import org.opensearch.security.user.AuthCredentials;
import org.opensearch.security.util.keyUtil;
import org.opensearch.security.util.keyUtils;

import static org.opensearch.security.OpenSearchSecurityPlugin.LEGACY_OPENDISTRO_PREFIX;
import static org.opensearch.security.OpenSearchSecurityPlugin.PLUGINS_PREFIX;
Expand Down Expand Up @@ -73,7 +73,7 @@ public OnBehalfOfAuthenticator(Settings settings, String clusterName) {
}

private JwtParser initParser(final String signingKey) {
JwtParser _jwtParser = keyUtil.createJwtParserFromSigningKey(signingKey, log);
JwtParser _jwtParser = keyUtils.createJwtParserFromSigningKey(signingKey, log);

if (_jwtParser == null) {
throw new RuntimeException("Unable to find on behalf of authenticator signing key");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
import java.util.Base64;
import java.util.Objects;

public class keyUtil {
public class keyUtils {

public static JwtParser createJwtParserFromSigningKey(final String signingKey, final Logger log) {
final SecurityManager sm = System.getSecurityManager();
Expand Down

0 comments on commit 2349213

Please sign in to comment.