INNER CODE UNIT · Rust

get_signature_agents

cloudflare/web-bot-auth · crates/web-bot-auth/src/lib.rs:327

    pub fn get_signature_agents(&self) -> &Vec<SignatureAgentLink> {
        &self.parsed_directories
    }

    /// Verify the messsage, consuming the verifier in the process.
    /// If `key_id` is not supplied, a key ID to fetch the public key
    /// from `keyring` will be sourced from the `keyid` parameter
    /// within the message.
    ///
    /// This fails closed when `created` is in the future or `expires` is in the
    /// past (or unparsable), returning [`WebBotAuthError::SignatureCreatedInFuture`]
    /// or [`WebBotAuthError::SignatureIsExpired`] before cryptographic verification.
    /// That matches the TypeScript `web-bot-auth` verifier. Callers that must
    /// process expired-but-valid signatures can opt into [`Self::verify_ignore_expiry`].
    pub fn verify(
        self,
        keyring: &KeyRing,
        key_id: Option<String>,

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…