pub struct CmsEncoder { /* private fields */ }Expand description
Wraps Security.framework CMS encoder state.
Implementations§
Source§impl CmsEncoder
impl CmsEncoder
Sourcepub fn set_signer_algorithm(
&mut self,
algorithm: CmsDigestAlgorithm,
) -> Result<()>
pub fn set_signer_algorithm( &mut self, algorithm: CmsDigestAlgorithm, ) -> Result<()>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn add_signers(&mut self, signers: &[Identity]) -> Result<()>
pub fn add_signers(&mut self, signers: &[Identity]) -> Result<()>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn signers(&self) -> Result<Value>
pub fn signers(&self) -> Result<Value>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn add_recipients(&mut self, recipients: &[Certificate]) -> Result<()>
pub fn add_recipients(&mut self, recipients: &[Certificate]) -> Result<()>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn recipients(&self) -> Result<Value>
pub fn recipients(&self) -> Result<Value>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn set_has_detached_content(&mut self, detached_content: bool) -> Result<()>
pub fn set_has_detached_content(&mut self, detached_content: bool) -> Result<()>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn has_detached_content(&self) -> Result<bool>
pub fn has_detached_content(&self) -> Result<bool>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn set_encapsulated_content_type_oid(&mut self, oid: &str) -> Result<()>
pub fn set_encapsulated_content_type_oid(&mut self, oid: &str) -> Result<()>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn encapsulated_content_type(&self) -> Result<Option<Vec<u8>>>
pub fn encapsulated_content_type(&self) -> Result<Option<Vec<u8>>>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn add_supporting_certificates(
&mut self,
certificates: &[Certificate],
) -> Result<()>
pub fn add_supporting_certificates( &mut self, certificates: &[Certificate], ) -> Result<()>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn supporting_certificates(&self) -> Result<Value>
pub fn supporting_certificates(&self) -> Result<Value>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn add_signed_attributes(
&mut self,
signed_attributes: CmsSignedAttributes,
) -> Result<()>
pub fn add_signed_attributes( &mut self, signed_attributes: CmsSignedAttributes, ) -> Result<()>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn set_certificate_chain_mode(
&mut self,
chain_mode: CmsCertificateChainMode,
) -> Result<()>
pub fn set_certificate_chain_mode( &mut self, chain_mode: CmsCertificateChainMode, ) -> Result<()>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn certificate_chain_mode(&self) -> Result<CmsCertificateChainMode>
pub fn certificate_chain_mode(&self) -> Result<CmsCertificateChainMode>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn update_content(&mut self, data: &[u8]) -> Result<()>
pub fn update_content(&mut self, data: &[u8]) -> Result<()>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn encoded_content(&self) -> Result<Vec<u8>>
pub fn encoded_content(&self) -> Result<Vec<u8>>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn signer_timestamp(
&self,
signer_index: usize,
) -> Result<Option<SystemTime>>
pub fn signer_timestamp( &self, signer_index: usize, ) -> Result<Option<SystemTime>>
Wraps the corresponding Security.framework CMS encoder operation.
Sourcepub fn signer_timestamp_with_policy(
&self,
policy: Option<&Policy>,
signer_index: usize,
) -> Result<Option<SystemTime>>
pub fn signer_timestamp_with_policy( &self, policy: Option<&Policy>, signer_index: usize, ) -> Result<Option<SystemTime>>
Wraps the corresponding Security.framework CMS encoder operation.