spiffe::svid

Trait SvidSource

Source
pub trait SvidSource {
    type Item: Svid;

    // Required method
    fn get_svid(
        &self,
    ) -> Result<Option<Self::Item>, Box<dyn Error + Send + Sync + 'static>>;
}
Expand description

Represents a source of SPIFFE SVIDs.

Required Associated Types§

Source

type Item: Svid

The type of the SVIDs provided by the source.

Required Methods§

Source

fn get_svid( &self, ) -> Result<Option<Self::Item>, Box<dyn Error + Send + Sync + 'static>>

Returns an owned SVID. If it cannot be found an SVID in the source, it returns Ok(None). If there’s is an error in source fetching the SVID, it returns an Err<Box<dyn Error + Send + Sync + 'static>>.

Implementors§