pub trait RootKeyProvider {
    // Required method
    fn choose(&self, key_id: Option<u32>) -> Result<PublicKey, Format>;
}
Expand description

Chooses a root public key to verify the token

In case of key rotation, it is possible to add a root key id to the token with BiscuitBuilder::set_root_key_id. This value will be passed to the implementor of RootKeyProvider to choose which key will be used.

Required Methods§

source

fn choose(&self, key_id: Option<u32>) -> Result<PublicKey, Format>

Trait Implementations§

Implementations on Foreign Types§

source§

impl RootKeyProvider for Box<dyn RootKeyProvider>

source§

fn choose(&self, key_id: Option<u32>) -> Result<PublicKey, Format>

source§

impl RootKeyProvider for Rc<dyn RootKeyProvider>

source§

fn choose(&self, key_id: Option<u32>) -> Result<PublicKey, Format>

source§

impl RootKeyProvider for Arc<dyn RootKeyProvider>

source§

fn choose(&self, key_id: Option<u32>) -> Result<PublicKey, Format>

Implementors§