Skip to main content

Cms

Struct Cms 

Source
pub struct Cms;
Expand description

Wraps convenience helpers around Security.framework CMS APIs.

Implementations§

Source§

impl Cms

Source

pub fn encoder() -> Result<CmsEncoder>

Wraps the corresponding Security.framework CMS helper.

Source

pub fn decoder() -> Result<CmsDecoder>

Wraps the corresponding Security.framework CMS helper.

Source

pub fn encode_supporting_certificates( certificates: &[Certificate], ) -> Result<Vec<u8>>

Wraps the corresponding Security.framework CMS helper.

Source

pub fn decode_all_certificates(data: &[u8]) -> Result<Vec<Certificate>>

Wraps the corresponding Security.framework CMS helper.

Source

pub fn encode_content( signers: &[Identity], recipients: &[Certificate], encapsulated_content_type_oid: Option<&str>, detached_content: bool, signed_attributes: CmsSignedAttributes, content: &[u8], ) -> Result<Vec<u8>>

Wraps the corresponding Security.framework CMS helper.

Auto Trait Implementations§

§

impl Freeze for Cms

§

impl RefUnwindSafe for Cms

§

impl Send for Cms

§

impl Sync for Cms

§

impl Unpin for Cms

§

impl UnsafeUnpin for Cms

§

impl UnwindSafe for Cms

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.