2017-05-11

Cryptography Engine Classes

The following engine classes are available:

  • SecureRandom: used to generate random or pseudo-random numbers.
             SecureRandom secureRandom = new SecureRandom()
             secureRandom.getInstance();
             secureRandom.getInstanceStrong()

             synchronized public void setSeed(byte[] seed)
             public void setSeed(long seed)

             synchronized public void nextBytes(byte[] bytes)

             byte[] generateSeed(int numBytes)

  • MessageDigest: used to calculate the message digest (hash) of specified data.

  • Signature: initialized with keys, these are used to sign data and verify digital signatures.

  • Cipher: initialized with keys, these used for encrypting/decrypting data. There are various types of algorithms: symmetric bulk encryption (e.g. AES, DES, DESede, Blowfish, IDEA), stream encryption (e.g. RC4), asymmetric encryption (e.g. RSA), and password-based encryption (PBE).

  • Message Authentication Codes (MAC): like MessageDigests, these also generate hash values, but are first initialized with keys to protect the integrity of messages.

  • KeyFactory: used to convert existing opaque cryptographic keys of type Key into key specifications (transparent representations of the underlying key material), and vice versa.

  • SecretKeyFactory: used to convert existing opaque cryptographic keys of type SecretKey into key specifications (transparent representations of the underlying key material), and vice versa. SecretKeyFactorys are specialized KeyFactorys that create secret (symmetric) keys only.

  • KeyPairGenerator: used to generate a new pair of public and private keys suitable for use with a specified algorithm.

  • KeyGenerator: used to generate new secret keys for use with a specified algorithm.

  • KeyAgreement: used by two or more parties to agree upon and establish a specific key to use for a particular cryptographic operation.

  • AlgorithmParameters: used to store the parameters for a particular algorithm, including parameter encoding and decoding.

  • AlgorithmParameterGenerator : used to generate a set of AlgorithmParameters suitable for a specified algorithm.

  • KeyStore: used to create and manage a keystore. A keystore is a database of keys. Private keys in a keystore have a certificate chain associated with them, which authenticates the corresponding public key. A keystore also contains certificates from trusted entities.

  • CertificateFactory: used to create public key certificates and Certificate Revocation Lists (CRLs).

  • CertPathBuilder: used to build certificate chains (also known as certification paths).

  • CertPathValidator: used to validate certificate chains.

  • CertStore: used to retrieve Certificates and CRLs from a repository.

No comments:

Post a Comment