Generate Diffie‐Hellman parameters with a legacy progress callback (deprecated).

Synopsis

Declared in <openssl/dh.h>

[[deprecated]]
DH*
DH_generate_parameters(
    int prime_len,
    int generator,
    void(* callback)(int, int, void*),
    void* cb_arg);
Warning

Deprecated. Use of this entity is allowed but discouraged.

Return Value

Newly allocated DH with generated parameters, or NULL on failure.

Parameters

Name

Description

prime_len

Desired length of the prime p in bits.

generator

DH generator g (commonly 2 or 5).

callback

Optional progress callback (int, int, void *), or NULL.

cb_arg

Opaque pointer passed to callback.

Created with MrDocs