Package org.mozilla.jss.tests
Class SymKeyGen
- java.lang.Object
-
- org.mozilla.jss.tests.SymKeyGen
-
public class SymKeyGen extends java.lang.ObjectMost of this code is Deprecated look at JCASymKeyGen.java for sample.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancipherTest(SymmetricKey key, EncryptionAlgorithm eAlg)IVParameterSpecgenIV(int blockSize)SymmetricKeygenPBAKey(KeyGenAlgorithm alg, SymmetricKey.Type keyType, int keyStrength)SymmetricKeygenPBEKey(PBEAlgorithm alg, SymmetricKey.Type keyType, int keyStrength)byte[]genSalt(int saltSize)SymmetricKeygenSymKey(KeyGenAlgorithm alg, SymmetricKey.Type keyType, int keyStrength, int keyLength)static voidmain(java.lang.String[] args)
-
-
-
Method Detail
-
genPBEKey
public SymmetricKey genPBEKey(PBEAlgorithm alg, SymmetricKey.Type keyType, int keyStrength) throws java.lang.Exception
- Throws:
java.lang.Exception
-
genPBAKey
public SymmetricKey genPBAKey(KeyGenAlgorithm alg, SymmetricKey.Type keyType, int keyStrength) throws java.lang.Exception
- Throws:
java.lang.Exception
-
genSymKey
public SymmetricKey genSymKey(KeyGenAlgorithm alg, SymmetricKey.Type keyType, int keyStrength, int keyLength) throws java.lang.Exception
- Throws:
java.lang.Exception
-
cipherTest
public boolean cipherTest(SymmetricKey key, EncryptionAlgorithm eAlg) throws java.lang.Exception
- Throws:
java.lang.Exception
-
genIV
public IVParameterSpec genIV(int blockSize) throws java.lang.Exception
- Throws:
java.lang.Exception
-
genSalt
public byte[] genSalt(int saltSize) throws java.lang.Exception- Throws:
java.lang.Exception
-
main
public static void main(java.lang.String[] args)
-
-