siphon_common/error.rs
1use thiserror::Error;
2
3/// Common errors for tunnel operations
4#[derive(Debug, Error)]
5pub enum TunnelError {
6 #[error("TLS error: {0}")]
7 Tls(String),
8
9 #[error("IO error: {0}")]
10 Io(#[from] std::io::Error),
11
12 #[error("Certificate error: {0}")]
13 Certificate(String),
14
15 #[error("Connection closed")]
16 ConnectionClosed,
17
18 #[error("Protocol error: {0}")]
19 Protocol(String),
20}