/// Create a new signature checker.
Create a new signature checker.
Create a new signature checker .
pub fn new() -> anyhow::Result<Self> {
        let keyring = {
            let mut keyring = Keyring::new();
            let key: Cow<'static, [u8]> =
                if let Some(value) = Assets::get("security@hashicorp.com.key") {
                    value
                } else {
                    anyhow::bail!("failed to load the embedded gpg key");
                };
            let _ = keyring.append_keys_from_armoured(key.to_vec().as_slice());
            keyring
        };
        Ok(Self { keyring })
    }
pub fn new ( ) -> anyhow :: Result < Self > { let keyring = { let mut keyring = Keyring :: new ( ) ; let key : Cow < ' static , [ u8 ] > = if let Some ( value ) = Assets :: get ( " " ) { value } else { anyhow :: bail ! ( " " ) ; } ; let _ = keyring . append_keys_from_armoured ( key . to_vec ( ) . as_slice ( ) ) ; keyring } ; Ok ( Self { keyring } ) }
Create a new signature checker.
Create a new signature checker .