Class DES.KeyFactory
- java.lang.Object
-
- javax.crypto.SecretKeyFactorySpi
-
- org.bouncycastle.jcajce.provider.symmetric.util.BaseSecretKeyFactory
-
- org.bouncycastle.jcajce.provider.symmetric.DES.KeyFactory
-
- All Implemented Interfaces:
PBE
- Enclosing class:
- DES
public static class DES.KeyFactory extends BaseSecretKeyFactory
-
-
Field Summary
-
Fields inherited from class org.bouncycastle.jcajce.provider.symmetric.util.BaseSecretKeyFactory
algName, algOid
-
Fields inherited from interface org.bouncycastle.jcajce.provider.symmetric.util.PBE
MD5, OPENSSL, PKCS12, PKCS5S1, PKCS5S1_UTF8, PKCS5S2, PKCS5S2_UTF8, SHA1, SHA256
-
-
Constructor Summary
Constructors Constructor Description KeyFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected SecretKeyengineGenerateSecret(KeySpec keySpec)Generate a secret key from the specified key specification.protected KeySpecengineGetKeySpec(SecretKey key, Class keySpec)Returns the key specification of the specified secret key.-
Methods inherited from class org.bouncycastle.jcajce.provider.symmetric.util.BaseSecretKeyFactory
engineTranslateKey
-
-
-
-
Method Detail
-
engineGetKeySpec
protected KeySpec engineGetKeySpec(SecretKey key, Class keySpec) throws InvalidKeySpecException
Description copied from class:SecretKeyFactorySpiReturns the key specification of the specified secret key.- Overrides:
engineGetKeySpecin classBaseSecretKeyFactory- Parameters:
key- the secret key to get the specification from.keySpec- the target key specification class.- Returns:
- an instance of the specified key specification class.
- Throws:
InvalidKeySpecException- if the specified secret key cannot be transformed into the requested key specification.
-
engineGenerateSecret
protected SecretKey engineGenerateSecret(KeySpec keySpec) throws InvalidKeySpecException
Description copied from class:SecretKeyFactorySpiGenerate a secret key from the specified key specification.- Overrides:
engineGenerateSecretin classBaseSecretKeyFactory- Parameters:
keySpec- the key specification.- Returns:
- a secret key.
- Throws:
InvalidKeySpecException- if the specified key specification cannot be used to generate a secret key.
-
-