ssh_agent_client_rs/
error.rs1use thiserror::Error;
3
4pub type Result<T> = std::result::Result<T, Error>;
6
7#[derive(Error, Debug)]
10pub enum Error {
11 #[error("Received an unknown message type: {0}")]
13 UnknownMessageType(u8),
14
15 #[error("An invalid message was received: {0}")]
17 InvalidMessage(String),
18
19 #[error("An error occurred communicating with the agent")]
21 AgentCommunicationError(#[from] std::io::Error),
22
23 #[error("An ssh key operation failed")]
25 SSHKey(#[from] ssh_key::Error),
26
27 #[error("An ssh encoding operation failed")]
29 SSHEncoding(#[from] ssh_encoding::Error),
30
31 #[error("The remote ssh agent returned the failure message")]
33 RemoteFailure,
34}