From 7c64d966956be47a285bdf8549a247faadb2e4e5 Mon Sep 17 00:00:00 2001
From: Prarthona Paul
Date: Thu, 10 Oct 2024 11:25:44 -0400
Subject: [PATCH] ELY-2831 Replace wildcard imports with specific imports
inside PasswordFactorySpiImpl.java
---
.../password/impl/PasswordFactorySpiImpl.java | 52 ++++++++++++++-----
1 file changed, 40 insertions(+), 12 deletions(-)
diff --git a/password/impl/src/main/java/org/wildfly/security/password/impl/PasswordFactorySpiImpl.java b/password/impl/src/main/java/org/wildfly/security/password/impl/PasswordFactorySpiImpl.java
index 50aa9e16f30..e665f5a3681 100644
--- a/password/impl/src/main/java/org/wildfly/security/password/impl/PasswordFactorySpiImpl.java
+++ b/password/impl/src/main/java/org/wildfly/security/password/impl/PasswordFactorySpiImpl.java
@@ -19,18 +19,46 @@
package org.wildfly.security.password.impl;
import static org.wildfly.security.password.impl.ElytronMessages.log;
-import static org.wildfly.security.password.interfaces.BCryptPassword.*;
-import static org.wildfly.security.password.interfaces.BSDUnixDESCryptPassword.*;
-import static org.wildfly.security.password.interfaces.ClearPassword.*;
-import static org.wildfly.security.password.interfaces.DigestPassword.*;
-import static org.wildfly.security.password.interfaces.OneTimePassword.*;
-import static org.wildfly.security.password.interfaces.ScramDigestPassword.*;
-import static org.wildfly.security.password.interfaces.SunUnixMD5CryptPassword.*;
-import static org.wildfly.security.password.interfaces.SimpleDigestPassword.*;
-import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.*;
-import static org.wildfly.security.password.interfaces.UnixSHACryptPassword.*;
-import static org.wildfly.security.password.interfaces.UnixMD5CryptPassword.*;
-import static org.wildfly.security.password.interfaces.UnixDESCryptPassword.*;
+import static org.wildfly.security.password.interfaces.BCryptPassword.ALGORITHM_BCRYPT;
+import static org.wildfly.security.password.interfaces.BSDUnixDESCryptPassword.ALGORITHM_BSD_CRYPT_DES;
+import static org.wildfly.security.password.interfaces.ClearPassword.ALGORITHM_CLEAR;
+import static org.wildfly.security.password.interfaces.DigestPassword.ALGORITHM_DIGEST_MD5;
+import static org.wildfly.security.password.interfaces.DigestPassword.ALGORITHM_DIGEST_SHA;
+import static org.wildfly.security.password.interfaces.DigestPassword.ALGORITHM_DIGEST_SHA_256;
+import static org.wildfly.security.password.interfaces.DigestPassword.ALGORITHM_DIGEST_SHA_384;
+import static org.wildfly.security.password.interfaces.DigestPassword.ALGORITHM_DIGEST_SHA_512;
+import static org.wildfly.security.password.interfaces.DigestPassword.ALGORITHM_DIGEST_SHA_512_256;
+import static org.wildfly.security.password.interfaces.OneTimePassword.ALGORITHM_OTP_MD5;
+import static org.wildfly.security.password.interfaces.OneTimePassword.ALGORITHM_OTP_SHA1;
+import static org.wildfly.security.password.interfaces.OneTimePassword.ALGORITHM_OTP_SHA_256;
+import static org.wildfly.security.password.interfaces.OneTimePassword.ALGORITHM_OTP_SHA_384;
+import static org.wildfly.security.password.interfaces.OneTimePassword.ALGORITHM_OTP_SHA_512;
+import static org.wildfly.security.password.interfaces.ScramDigestPassword.ALGORITHM_SCRAM_SHA_1;
+import static org.wildfly.security.password.interfaces.ScramDigestPassword.ALGORITHM_SCRAM_SHA_256;
+import static org.wildfly.security.password.interfaces.ScramDigestPassword.ALGORITHM_SCRAM_SHA_384;
+import static org.wildfly.security.password.interfaces.ScramDigestPassword.ALGORITHM_SCRAM_SHA_512;
+import static org.wildfly.security.password.interfaces.SunUnixMD5CryptPassword.ALGORITHM_SUN_CRYPT_MD5;
+import static org.wildfly.security.password.interfaces.SunUnixMD5CryptPassword.ALGORITHM_SUN_CRYPT_MD5_BARE_SALT;
+import static org.wildfly.security.password.interfaces.SimpleDigestPassword.ALGORITHM_SIMPLE_DIGEST_MD2;
+import static org.wildfly.security.password.interfaces.SimpleDigestPassword.ALGORITHM_SIMPLE_DIGEST_MD5;
+import static org.wildfly.security.password.interfaces.SimpleDigestPassword.ALGORITHM_SIMPLE_DIGEST_SHA_1;
+import static org.wildfly.security.password.interfaces.SimpleDigestPassword.ALGORITHM_SIMPLE_DIGEST_SHA_256;
+import static org.wildfly.security.password.interfaces.SimpleDigestPassword.ALGORITHM_SIMPLE_DIGEST_SHA_384;
+import static org.wildfly.security.password.interfaces.SimpleDigestPassword.ALGORITHM_SIMPLE_DIGEST_SHA_512;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_PASSWORD_SALT_DIGEST_MD5;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_PASSWORD_SALT_DIGEST_SHA_1;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_PASSWORD_SALT_DIGEST_SHA_256;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_PASSWORD_SALT_DIGEST_SHA_384;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_PASSWORD_SALT_DIGEST_SHA_512;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_SALT_PASSWORD_DIGEST_MD5;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_SALT_PASSWORD_DIGEST_SHA_1;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_SALT_PASSWORD_DIGEST_SHA_256;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_SALT_PASSWORD_DIGEST_SHA_384;
+import static org.wildfly.security.password.interfaces.SaltedSimpleDigestPassword.ALGORITHM_SALT_PASSWORD_DIGEST_SHA_512;
+import static org.wildfly.security.password.interfaces.UnixSHACryptPassword.ALGORITHM_CRYPT_SHA_256;
+import static org.wildfly.security.password.interfaces.UnixSHACryptPassword.ALGORITHM_CRYPT_SHA_512;
+import static org.wildfly.security.password.interfaces.UnixMD5CryptPassword.ALGORITHM_CRYPT_MD5;
+import static org.wildfly.security.password.interfaces.UnixDESCryptPassword.ALGORITHM_CRYPT_DES;
import java.nio.charset.Charset;
import java.security.InvalidAlgorithmParameterException;