pub struct SignedData {
pub version: u64,
pub digest_algorithms: Vec<(Vec<u64>, Vec<u8>)>,
pub encap_content_type: Vec<u64>,
pub encap_content_octets: Option<Vec<u8>>,
pub certs: Vec<Vec<u8>>,
pub crls: Vec<Vec<u8>>,
pub signer_infos: Vec<SignerInfo>,
}Expand description
Parsed CMS SignedData reduced to the fields a PDF signature
reader needs.
Fields§
§version: u64CMS SignedData version — 1, 3, 4, or 5 (RFC 5652 §5.1).
digest_algorithms: Vec<(Vec<u64>, Vec<u8>)>digestAlgorithms SET — each entry is (oid_arcs, params_raw_bytes).
encap_content_type: Vec<u64>encapContentInfo.eContentType OID arcs. For attached PDF
signatures this is id-data (1.2.840.113549.1.7.1); for
detached PAdES signatures it’s still id-data but the
eContent octets are absent — the bytes to verify are the
PDF byte ranges in /ByteRange.
encap_content_octets: Option<Vec<u8>>encapContentInfo.eContent octets — Some(bytes) for
attached signatures, None when omitted (typical PAdES /
detached). The bytes here are the OCTET STRING body — no DER
header, no [0] wrapper.
certs: Vec<Vec<u8>>certificates[0] IMPLICIT CertificateSet OPTIONAL — each
entry is the raw DER bytes of one CertificateChoices
alternative (typically an X.509 v3 SEQUENCE; we surface every
alternative shape as opaque DER so the caller can dispatch on
the outer tag). Empty vec when the field was absent.
crls: Vec<Vec<u8>>crls[1] IMPLICIT RevocationInfoChoices OPTIONAL — each
entry is the raw DER bytes of one RevocationInfoChoices
alternative (typically an X.509 CertificateList SEQUENCE).
Empty vec when the field was absent.
signer_infos: Vec<SignerInfo>signerInfos SET OF SignerInfo — typically one entry for a
single-signer PDF, but the spec permits multiple.
Trait Implementations§
Source§impl Clone for SignedData
impl Clone for SignedData
Source§fn clone(&self) -> SignedData
fn clone(&self) -> SignedData
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more