Build a PKCS#5 PBES2 AlgorithmIdentifier for cipher with optional IV and PBKDF2 PRF.

Synopsis

Declared in <openssl/x509.h>

X509_ALGOR*
PKCS5_pbe2_set_iv(
    EVP_CIPHER const* cipher,
    int iter,
    unsigned char* salt,
    int saltlen,
    unsigned char* aiv,
    int prf_nid);

Return Value

Newly allocated X509_ALGOR, or NULL on error.

Parameters

Name

Description

cipher

Cipher that defines the encryption scheme.

iter

PBKDF2 iteration count.

salt

Salt bytes, or NULL as implemented.

saltlen

Length of salt in bytes.

aiv

Explicit IV bytes, or NULL to generate one.

prf_nid

NID of the PBKDF2 PRF, or 0 for the default.

Created with MrDocs