-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
P3
-
None
-
Affects Version/s: 8
-
Component/s: security-libs
-
generic
-
solaris
cat CipherInstanceTest1.java
import javax.crypto.Cipher;
public class CipherInstanceTest1 {
public static void main(String[] args) {
try {
Cipher cipher = Cipher.getInstance("AES", "OracleUcrypto");
System.out.println("AES cipher acquired: " + cipher.getProvider());
} catch (Exception e) {
System.out.println("Failed to get AES cipher:");
e.printStackTrace();
}
try {
Cipher cipher2 = Cipher.getInstance("RSA", "OracleUcrypto");
System.out.println("RSA cipher acquired: " + cipher2.getProvider());
} catch (Exception e) {
System.out.println("Failed to get RSA cipher:");
e.printStackTrace();
}
}
}
*****
./jdk8/bin/java CipherInstanceTest1
warning: JDK development build detected. No jar verification of crypto jars enforced.
Failed to get AES cipher:
java.security.NoSuchAlgorithmException: No such algorithm: AES
at javax.crypto.Cipher.getInstance(Cipher.java:707)
at javax.crypto.Cipher.getInstance(Cipher.java:604)
at CipherInstanceTest1.main(CipherInstanceTest1.java:6)
Failed to get RSA cipher:
java.security.NoSuchAlgorithmException: No such algorithm: RSA
at javax.crypto.Cipher.getInstance(Cipher.java:707)
at javax.crypto.Cipher.getInstance(Cipher.java:604)
at CipherInstanceTest1.main(CipherInstanceTest1.java:14)
JDK 8 docs say they should be offered:
https://docs.oracle.com/javase/8/docs/technotes/guides/security/SunProviders.html#OracleUcrypto
import javax.crypto.Cipher;
public class CipherInstanceTest1 {
public static void main(String[] args) {
try {
Cipher cipher = Cipher.getInstance("AES", "OracleUcrypto");
System.out.println("AES cipher acquired: " + cipher.getProvider());
} catch (Exception e) {
System.out.println("Failed to get AES cipher:");
e.printStackTrace();
}
try {
Cipher cipher2 = Cipher.getInstance("RSA", "OracleUcrypto");
System.out.println("RSA cipher acquired: " + cipher2.getProvider());
} catch (Exception e) {
System.out.println("Failed to get RSA cipher:");
e.printStackTrace();
}
}
}
*****
./jdk8/bin/java CipherInstanceTest1
warning: JDK development build detected. No jar verification of crypto jars enforced.
Failed to get AES cipher:
java.security.NoSuchAlgorithmException: No such algorithm: AES
at javax.crypto.Cipher.getInstance(Cipher.java:707)
at javax.crypto.Cipher.getInstance(Cipher.java:604)
at CipherInstanceTest1.main(CipherInstanceTest1.java:6)
Failed to get RSA cipher:
java.security.NoSuchAlgorithmException: No such algorithm: RSA
at javax.crypto.Cipher.getInstance(Cipher.java:707)
at javax.crypto.Cipher.getInstance(Cipher.java:604)
at CipherInstanceTest1.main(CipherInstanceTest1.java:14)
JDK 8 docs say they should be offered:
https://docs.oracle.com/javase/8/docs/technotes/guides/security/SunProviders.html#OracleUcrypto
- relates to
-
JDK-8043349 Consider adding aliases for Ucrypto algorithm-only Cipher transformations.
-
- Resolved
-
-
JDK-8374112 Add test to check documented algorithms against providers
-
- New
-