code: static org.bouncycastle.crypto.params.DHParameters getDhParameters(SecureRandom random,
          DHKeyParametersGenerationParameters params)
      {
          DHParametersGenerator paramGen = new DHParametersGenerator();
  
          paramGen.init(params.getStrength() * 8, params.getCertainty(), random);
  
          return paramGen.generateParameters();
      }
docs: Generate DH parameters.
  
  Shared with the key generator to optimize key generation.
  
  @param params the parameters generation parameters.
  @return shared DSA parameters for key generation.