PEM_write_bio_ECPrivateKey

Write an EC private key to a BIO in PEM form (deprecated).

Synopsis

Declared in <openssl/pem.h>

[[deprecated]]
int
PEM_write_bio_ECPrivateKey(
    BIO* bp,
    EC_KEY const* x,
    EVP_CIPHER const* enc,
    unsigned char const* kstr,
    int klen,
    pem_password_cb* cb,
    void* u);

WARNING

Deprecated. Use of this entity is allowed but discouraged.

Return Value

1 on success, or 0 on failure.

Parameters

NameDescription
bpBIO to write to.
xEC_KEY to encode.
encOptional cipher for traditional PEM encryption, or NULL for cleartext.
kstrOptional encryption key bytes used with enc, or NULL to prompt via cb.
klenLength of kstr when provided.
cbPassword callback when encryption needs a passphrase, or NULL.
uApplication data passed to cb.