Class DHKeyGenerationParameters

    • Constructor Detail

      • DHKeyGenerationParameters

        public DHKeyGenerationParameters​(BigInteger p,
                                         BigInteger g)
        Initialize DH parameters.
        Parameters:
        p - public (prime) number P.
        g - the public (prime) base G.
      • DHKeyGenerationParameters

        public DHKeyGenerationParameters​(BigInteger p,
                                         BigInteger g,
                                         BigInteger q)
        Initialize DH parameters.
        Parameters:
        p - public (prime) number P.
        g - the public (prime) base G.
        q - the Sophie Germain prime Q.
      • DHKeyGenerationParameters

        public DHKeyGenerationParameters​(BigInteger p,
                                         BigInteger g,
                                         BigInteger q,
                                         int l)
        Initialize DH parameters.
        Parameters:
        p - public (prime) number P.
        g - the public (prime) base G.
        q - the Sophie Germain prime Q.
        l - the private value length in bytes.
      • DHKeyGenerationParameters

        public DHKeyGenerationParameters​(BigInteger p,
                                         BigInteger g,
                                         BigInteger q,
                                         int m,
                                         int l)
        Initialize DH parameters.
        Parameters:
        p - public (prime) number P.
        g - the public (prime) base G.
        q - the Sophie Germain prime Q.
        m - the minimum length of the private value in bytes.
        l - the private value length in bytes.
      • DHKeyGenerationParameters

        public DHKeyGenerationParameters​(BigInteger p,
                                         BigInteger g,
                                         BigInteger q,
                                         BigInteger j,
                                         DHKeyValidationParameters parameters)
        Initialize DH parameters.
        Parameters:
        p - public (prime) number P.
        g - the public (prime) base G.
        q - the Sophie Germain prime Q.
        j - the subgroup factor J.
        parameters - the validation parameters.
      • DHKeyGenerationParameters

        public DHKeyGenerationParameters​(BigInteger p,
                                         BigInteger g,
                                         BigInteger q,
                                         int m,
                                         int l,
                                         BigInteger j,
                                         DHKeyValidationParameters parameters)
        Initialize DH parameters.
        Parameters:
        p - public (prime) number P.
        g - the public (prime) base G.
        q - the Sophie Germain prime Q.
        m - the minimum length of the private value in bytes.
        l - the private value length in bytes.
        j - the subgroup factor J.
        parameters - the validation parameters.
    • Method Detail

      • getP

        public BigInteger getP()
        Returns:
        the public (prime) number P.
      • getG

        public BigInteger getG()
        Returns:
        the public (prime) base G.
      • getQ

        public BigInteger getQ()
        Returns:
        the Sophie Germain prime Q.
      • getM

        public int getM()
        Returns:
        the minimum length of the private value in bytes.
      • getL

        public int getL()
        Returns:
        the private value length in bytes - if set, zero otherwise.
      • getJ

        public BigInteger getJ()
        Returns:
        the subgroup factor j.