jclass
Class RandomKeyGenerator

java.lang.Object
  |
  +--jclass.RandomKeyGenerator

public class RandomKeyGenerator
extends java.lang.Object

A random key generator used in generating variable length keys.

Written: Radu Sion
Version: 0.1
Source: RandomKeyGenerator.java

Visit Smart Software 


Constructor Summary
RandomKeyGenerator()
           
 
Method Summary
static byte[] newKey(byte length)
          Generates a new random key of a given length.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RandomKeyGenerator

public RandomKeyGenerator()
Method Detail

newKey

public static byte[] newKey(byte length)
Generates a new random key of a given length.
Parameters:
The - length of the generated key. If neg or 0 the length is random.
Returns:
Random generated key