pem_rfc7468

Function decode

Source
pub fn decode<'i, 'o>(
    pem: &'i [u8],
    buf: &'o mut [u8],
) -> Result<(&'i str, &'o [u8])>
Expand description

Decode a PEM document according to RFC 7468’s “Strict” grammar.

On success, writes the decoded document into the provided buffer, returning the decoded label and the portion of the provided buffer containing the decoded message.