Skip to main content

Verify

Trait Verify 

Source
pub trait Verify: Send + Sync {
    // Required method
    fn verify(&self, user: &[u8], password: &[u8]) -> Option<String>;

    // Provided method
    fn trusted(&self, user: &[u8]) -> bool { ... }
}
Expand description

Checks credentials the proxy does not hold: those the standalone proxy’s sessions were issued after it started (ADR-044). The CLI implements it.

Required Methods§

Source

fn verify(&self, user: &[u8], password: &[u8]) -> Option<String>

The audit session that user and password authenticate, or None. The comparison must take time that does not depend on where a guess first differs from a valid credential.

Provided Methods§

Source

fn trusted(&self, user: &[u8]) -> bool

Whether the session of user, a credential Self::verify just accepted, received the trust files of the proxy’s certificate authority (ADR-062), so its tunnels to requests: hosts may be terminated. false unless the implementation says so.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§