Set the public and/or private key BIGNUMs on a DH object, transferring ownership (deprecated).

Synopsis

Declared in <openssl/dh.h>

[[deprecated]]
int
DH_set0_key(
    DH* dh,
    BIGNUM* pub_key,
    BIGNUM* priv_key);
Warning

Deprecated. Use of this entity is allowed but discouraged.

Description

Non‐NULL values are owned by dh after a successful call and must not be freed by the caller.

Return Value

1 on success, or 0 on failure.

Parameters

Name

Description

dh

DH object to update.

pub_key

New public value, or NULL to leave the existing public key unchanged.

priv_key

New private value, or NULL to leave the existing private key unchanged.

Created with MrDocs