8343622: AesDkCrypto.stringToKey should not return null

Reviewed-by: valeriep
This commit is contained in:
Weijun Wang 2024-12-05 08:36:18 +00:00
parent e46d822aeb
commit ca46c3a5ba
6 changed files with 59 additions and 16 deletions

View file

@ -72,13 +72,8 @@ public final class MD4 extends DigestBase {
md4Provider.put("MessageDigest.MD4", "sun.security.provider.MD4");
}
public static MessageDigest getInstance() {
try {
return MessageDigest.getInstance("MD4", md4Provider);
} catch (NoSuchAlgorithmException e) {
// should never occur
throw new ProviderException(e);
}
public static MessageDigest getInstance() throws NoSuchAlgorithmException {
return MessageDigest.getInstance("MD4", md4Provider);
}
// Standard constructor, creates a new MD4 instance.