Skip to main content

Crate noxtls_pem

Crate noxtls_pem 

Source
Expand description

PEM encoding and decoding helpers for certificates, keys, and generic DER payloads.

Supports no_std builds with alloc and optional std helpers for filesystem I/O.

Functionsยง

certificate_chain_pem_to_der_blocks
Parses all PEM CERTIFICATE blocks into DER bytes.
certificate_der_to_pem
Converts certificate DER bytes into PEM CERTIFICATE armor.
certificate_pem_to_der
Parses one PEM CERTIFICATE block into DER bytes.
der_to_file
Writes raw DER bytes to a file path.
der_to_pem
Converts DER bytes into PEM armor with caller-provided label.
der_to_pem_file
Encodes DER as PEM and writes it to a file path.
ec_private_key_der_to_pem_sec1
Converts SEC1 EC private-key DER bytes into PEM armor.
ec_private_key_pem_to_der_sec1
Parses one PEM SEC1 EC private-key block into DER bytes.
pem_file_to_der
Reads one PEM block from file and decodes DER payload for label.
pem_file_to_der_blocks
Reads all matching PEM blocks from file and decodes DER payloads for label.
pem_to_der
Parses PEM armor into DER bytes and verifies expected label markers.
pem_to_der_blocks
Parses all PEM blocks matching label into DER payload bytes.
private_key_der_to_pem_pkcs8
Converts PKCS#8 private-key DER bytes into PEM armor.
private_key_pem_to_der_pkcs8
Parses one PEM PKCS#8 private-key block into DER bytes.
public_key_der_to_pem_spki
Converts SubjectPublicKeyInfo DER bytes into PEM armor.
public_key_pem_to_der_spki
Parses one PEM SPKI public-key block into DER bytes.
rsa_private_key_der_to_pem_pkcs1
Converts PKCS#1 RSA private-key DER bytes into PEM armor.
rsa_private_key_pem_to_der_pkcs1
Parses one PEM PKCS#1 RSA private-key block into DER bytes.
rsa_public_key_der_to_pem_pkcs1
Converts PKCS#1 RSA public-key DER bytes into PEM armor.
rsa_public_key_pem_to_der_pkcs1
Parses one PEM PKCS#1 RSA public-key block into DER bytes.