Skip to main content

SshResolver

Trait SshResolver 

Source
pub trait SshResolver: Send + Sync {
    // Required method
    fn resolve(&self, operation: SshOperation) -> Result<SshAuth, ApiError>;
}
Expand description

Hook called once per LFS API request to resolve SSH-mediated auth.

Implementations are typically backed by a git-lfs-authenticate invocation with a small in-memory cache keyed on (host, path, operation) so the SSH command runs at most once per cache TTL.

Required Methods§

Source

fn resolve(&self, operation: SshOperation) -> Result<SshAuth, ApiError>

Return the auth response for operation. Ok(default) (empty href, empty headers) means “no SSH override — use the configured endpoint with whatever auth is already on the request”.

Implementors§