Struct sbat::RevocationSbatVec

source ·
pub struct RevocationSbatVec<'a> { /* private fields */ }
Expand description

SBAT revocation data.

This contains SBAT revocation data parsed from a UEFI variable such as SbatLevel.

See the crate documentation for a usage example.

Implementations§

source§

impl<'a> RevocationSbatVec<'a>

source

pub fn new() -> Self

Create an empty RevocationSbatVec.

Trait Implementations§

source§

impl<'a> Clone for RevocationSbatVec<'a>

source§

fn clone(&self) -> RevocationSbatVec<'a>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<'a> Debug for RevocationSbatVec<'a>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'a> Default for RevocationSbatVec<'a>

source§

fn default() -> RevocationSbatVec<'a>

Returns the “default value” for a type. Read more
source§

impl<'a> PartialEq<RevocationSbatVec<'a>> for RevocationSbatVec<'a>

source§

fn eq(&self, other: &RevocationSbatVec<'a>) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl<'a> RevocationSbat<'a> for RevocationSbatVec<'a>

source§

fn date(&self) -> Option<&AsciiStr>

Date when the data was last updated. This is optional metadata in the first entry and may not be present.
source§

fn set_date(&mut self, date: Option<&'a AsciiStr>)

Set the date when the data was last updated.
source§

fn revoked_components(&self) -> &[Component<'a>]

Get the revoked components as a slice. The component version indicates the lowest allowed version of this component; all lower versions are considered revoked.
source§

fn try_push(&mut self, component: Component<'a>) -> Result<(), PushError>

Add a revoked component.
source§

fn parse(input: &'a [u8]) -> Result<Self, ParseError>

Parse SBAT data from raw CSV. This data typically comes from a UEFI variable. Each record is parsed as a Component. Read more
source§

fn validate_image<I: ImageSbat<'a>>( &self, image_sbat: &I ) -> ValidationResult<'a>

Check if any component in image_sbat is revoked. Read more
source§

fn is_component_revoked(&self, input: &Component<'_>) -> bool

Check if the input Component is revoked. Read more
source§

impl<'a> Eq for RevocationSbatVec<'a>

source§

impl<'a> StructuralEq for RevocationSbatVec<'a>

source§

impl<'a> StructuralPartialEq for RevocationSbatVec<'a>

Auto Trait Implementations§

§

impl<'a> RefUnwindSafe for RevocationSbatVec<'a>

§

impl<'a> Send for RevocationSbatVec<'a>

§

impl<'a> Sync for RevocationSbatVec<'a>

§

impl<'a> Unpin for RevocationSbatVec<'a>

§

impl<'a> UnwindSafe for RevocationSbatVec<'a>

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere 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 Twhere 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> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

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

§

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 Twhere U: TryFrom<T>,

§

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.