cryptix.examples.pgp
Class VanityKeyGen
java.lang.Object
cryptix.examples.pgp.KeyGen
cryptix.examples.pgp.VanityKeyGen
- All Implemented Interfaces:
- RSAKeyGenObserver, TestPrimeObserver
- public final class VanityKeyGen
- extends KeyGen
Field Summary |
protected java.io.DataInputStream |
in
|
protected java.io.PrintStream |
out
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
in
protected java.io.DataInputStream in
out
protected java.io.PrintStream out
VanityKeyGen
public VanityKeyGen()
main
public static void main(java.lang.String[] argv)
getKey
protected SecretKey getKey(int length,
RandomStream rs)
- Overrides:
getKey
in class KeyGen
begin
protected final void begin()
getUserName
protected java.lang.String getUserName()
throws java.io.IOException
- Throws:
java.io.IOException
getKeyLength
protected int getKeyLength()
throws java.io.IOException
- Throws:
java.io.IOException
getRandomStream
protected RandomStream getRandomStream(int keyLength)
throws java.io.IOException
- This is NOT VERY SECURE as the seed is rather simplistic.
- Throws:
java.io.IOException
getPassphrase
protected java.lang.String getPassphrase()
throws java.io.IOException
- WARNING this prints the passphrase out on to the screen.
- Throws:
java.io.IOException
handleEvent
public void handleEvent(int evnt)
- Specified by:
handleEvent
in interface TestPrimeObserver