Allocate and fill an OSSL_PARAM from a textual key/value using a param definition list.

Synopsis

Declared in <openssl/params.h>

int
OSSL_PARAM_allocate_from_text(
    OSSL_PARAM* to,
    OSSL_PARAM const* paramdefs,
    char const* key,
    char const* value,
    size_t value_n,
    int* found);

Return Value

1 on success, or 0 on failure.

Parameters

Name

Description

to

Destination parameter; on success owns freshly allocated data that the caller must free.

paramdefs

Array of parameter definitions describing allowed keys and types.

key

Parameter name to look up in paramdefs.

value

Textual representation of the value (encoding depends on the matched type).

value_n

Length of value in bytes (not necessarily NUL‐terminated).

found

Optional; set to 1 if key was found in paramdefs, else 0.

Created with MrDocs