Package org.conscrypt
Class KeySpecUtil
java.lang.Object
org.conscrypt.KeySpecUtil
A utility class for working with KeySpecs.
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T extends KeySpec>
TmakeRawKeySpec(byte[] bytes, Class<T> keySpecClass) Creates a KeySpec object for the provided keySpecClass.
-
Method Details
-
makeRawKeySpec
public static <T extends KeySpec> T makeRawKeySpec(byte[] bytes, Class<T> keySpecClass) throws InvalidKeySpecException Creates a KeySpec object for the provided keySpecClass. The KeySpec must be a subclass of EncodedKeySpec and its getFormat() method must return "raw".- Throws:
InvalidKeySpecException
-