Constant cellar_pkcs8::PKCS8_DOCUMENT_MAX_LEN[][src]

pub const PKCS8_DOCUMENT_MAX_LEN: usize = 40 + SCALAR_MAX_BYTES + PUBLIC_KEY_MAX_LEN; // 0x0_000_000_000_000_0b9usize

The maximum length of a PKCS#8 documents generated by ring for ECC keys.

This is NOT the maximum length of a PKCS#8 document that can be consumed by pkcs8::unwrap_key().

40 is the length of the P-384 template. It is actually one byte shorter than the P-256 template, but the private key and the public key are much longer.