This section provides a tutorial example on how to write simple program to generate a pair of private key and public key for the RSA or DSA algorithm.
The following sample program shows you how to invoke the key pair generation algorithms
implemented by the default provider, Sun, and generate key pairs.