sftp-server 0.1.0

Library providing a pure Rust implementation of an SFTP server; can operate standalone with an embedded SSH server, or can provide the SFTP backend for an external SSH server (e.g. openssh). Binary crates should pull in this library and provide their own storage back-end.
Documentation
#[derive(thiserror::Error, Debug)]
pub enum Error {
	#[error("I/O error:  {0}")]
	IO(#[from] std::io::Error),
	#[error("SFTP protocol error:  {0}")]
	Protocol(#[from] sftp_protocol::Error),
	#[error("Binary encoding error:  {0}")]
	Bincode(#[from] bincode::ErrorKind),
	#[cfg_attr(feature = "standalone", error("SSH error:  {0}"))]
	#[cfg(feature = "standalone")]
	Thrussh(#[from] thrussh::Error),
	#[error("Invalid path")]
	InvalidPath,
	#[error("UTF-8 path error")]
	Utf8Path(#[from] camino::FromPathBufError),
	#[error("metadata error")]
	Metadata(#[from] nix::Error)
}

impl From<Box<bincode::ErrorKind>> for Error {
	fn from(inner: Box<bincode::ErrorKind>) -> Self {
		Self::Bincode(*inner)
	}
}