EVP_PKEY_auth_encapsulate_init

Initialize authenticated key encapsulation using a peer public key and auth private key.

Synopsis

Declared in <openssl/evp.h>

int
EVP_PKEY_auth_encapsulate_init(
    EVP_PKEY_CTX* ctx,
    EVP_PKEY* authpriv,
    OSSL_PARAM const params[]);

Return Value

1 on success, or 0 / a negative value on failure.

Parameters

NameDescription
ctxContext created for a KEM algorithm (recipient/public key already set as needed).
authprivPrivate key used for authentication during encapsulation.
paramsOptional OSSL_PARAM array of algorithm parameters, or NULL.