[#PEM_bytes_read_bio] = PEM_bytes_read_bio :mrdocs: Read a named PEM object from a BIO, decrypting if needed, and return its DER bytes. == Synopsis Declared in `<openssl/pem.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int PEM_bytes_read_bio( unsigned char** pdata, long* plen, char** pnm, char const* name, xref:BIO.adoc[BIO]* bp, xref:pem_password_cb.adoc[pem_password_cb]* cb, void* u); ---- == Return Value 1 on success, or 0 on failure. == Parameters [cols="1,4"] |=== | Name| Description | *pdata* | Receives newly allocated DER payload (caller frees with OPENSSL_free). | *plen* | Receives the length of *`pdata` in bytes. | *pnm* | Optional; receives the actual PEM type name from the BEGIN line (caller frees). | *name* | Expected PEM type label (for example "CERTIFICATE"); non‐matching types are skipped. | *bp* | BIO to read from. | *cb* | Password callback for encrypted PEM, or NULL. | *u* | Application data passed to `cb.` |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#