Class KeyGenAlgorithm

  • Direct Known Subclasses:
    PBEAlgorithm

    public class KeyGenAlgorithm
    extends Algorithm
    Algorithms that can be used for generating symmetric keys.
    • Method Detail

      • fromOID

        public static KeyGenAlgorithm fromOID​(OBJECT_IDENTIFIER oid)
                                       throws java.security.NoSuchAlgorithmException
        Throws:
        java.security.NoSuchAlgorithmException
      • isValidStrength

        public boolean isValidStrength​(int strength)
        Parameters:
        strength - Key strength.
        Returns:
        true if the given strength is valid for this key generation algorithm. Note that PBE algorithms require PBEParameterSpecs rather than strengths. It is the responsibility of the caller to verify this.