class SecurityUtils {

  public static String randomAlphanumeric(int length) {
    StringBuilder buffer = new StringBuilder(length);
    SecureRandom secureRandom = new SecureRandom();
    for (int i = 0; i < length; i++) {
      double number = secureRandom.nextDouble();
      int b = ((int) (number * ALPHANUM_ARRAY.length));
      buffer.append(ALPHANUM_ARRAY[b]);
    }
    return buffer.toString();
  }

}