My favorites | Sign in
Project Home Source
Project Information
Members
Links

Random number and password generation

Java classes for random number generation:

  • password,
  • key,
  • md5,
Builds with maven2.

Password generation is not so easy. There are two common errors with random password generation:

  • generated password is inelegant word, for example: "1something2"
  • generated password containst problematic charactes, for example: "1" and "l" or "O" and "0"
This classes help you to generate good password.

Usage

// create new password for sms or email sending (about 1e5 combination)
String password = new PasswordGenerator().generate();

// create new password (about 1e10 combination)
String strongPassword = new StrongPasswordGenerator().generate()

// create statistically unique key (about 2e39 combination) - 22 chars safly for URLs
String key = new KeyGenerator().generate();

// create random hex encoded MD5 (2^128 combination) - 32 chars
String md5 = new Md5HexGenerator().generate();

Installation

svn checkout http://jakubiak-generators.googlecode.com/svn/trunk/ jakubiak-generators-read-only
cd jakubiak-generators-read-only/jakubiak-generators/
mvn clean install

Maven2

<dependency>
  <groupId>eu.jakubiak</groupId>
  <artifactId>jakubiak-generators</artifactId>
  <version>1.0-SNAPSHOT</version>
</dependency>
Powered by Google Project Hosting