generate Key Pair
Utility to simplify the act of generating keys. Normally, we don't expect other errors here, assuming that key generation parameters for every supported signature scheme have been unit-tested.
Return
a KeyPair for the requested signature scheme code name.
Parameters
scheme Code Name
a signature scheme's code name (e.g. ECDSA_SECP256K1_SHA256).
Throws
if the requested signature scheme is not supported.
Generate a KeyPair for the selected SignatureScheme. Note that RSA is the sole algorithm initialized specifically by its supported keySize.
Return
a new KeyPair for the requested SignatureScheme.
Parameters
signature Scheme
a supported SignatureScheme, see Crypto, default to DEFAULT_SIGNATURE_SCHEME if not provided.
Throws
if the requested signature scheme is not supported.