[][src]Struct rpki::sigobj::SignedObject

pub struct SignedObject { /* fields omitted */ }

A signed object.

Signed objects are a more strict profile of a CMS signed-data object. They are specified in [RFC 6088] while CMS is specified in [RFC 5652].

Methods

impl SignedObject[src]

pub fn decode<S: Source>(source: S, strict: bool) -> Result<Self, S::Err>[src]

pub fn content_type(&self) -> &Oid<Bytes>[src]

Returns a reference to the object’s content type.

pub fn content(&self) -> &OctetString[src]

Returns a reference to the object’s content.

pub fn decode_content<F, T>(&self, op: F) -> Result<T, Error> where
    F: FnOnce(&mut Constructed<OctetStringSource>) -> Result<T, Error>, 
[src]

pub fn cert(&self) -> &Cert[src]

Returns a reference to the certificate the object is signed with.

impl SignedObject[src]

pub fn take_from<S: Source>(cons: &mut Constructed<S>) -> Result<Self, S::Err>[src]

pub fn take_encap_content_info<S: Source>(
    cons: &mut Constructed<S>
) -> Result<(Oid<Bytes>, OctetString), S::Err>
[src]

Parses an EncapsulatedContentInfo value.

For a ROA, eContentType must be oid:::ROUTE_ORIGIN_AUTH.

pub fn validate(
    self,
    issuer: &ResourceCert,
    strict: bool
) -> Result<ResourceCert, ValidationError>
[src]

Validates the signed object.

The requirements for an object to be valid are given in section 3 of [RFC 6488].

Upon success, the method returns the validated certificate and the content.

pub fn validate_at(
    self,
    issuer: &ResourceCert,
    strict: bool,
    now: Time
) -> Result<ResourceCert, ValidationError>
[src]

Trait Implementations

impl Clone for SignedObject[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for SignedObject[src]

Auto Trait Implementations

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.