firetrap/
lib.rs

1#![deny(missing_docs)]
2//! FTP server library for Rust
3//!
4//! Firetrap helps you create modern, safe and extensible FTP servers in Rust.
5//!
6//! Because of its plugable authentication and storage backends (e.g. local filesystem, Google
7//! Buckets) it's more flexible than traditional FTP servers and a perfect match for the cloud.
8//!
9//! It is currently under heavy development and not yet recommended for production use.
10//!
11//! # Quick Start
12//!
13//! ```rust
14//! extern crate firetrap;
15//!
16//! fn main() {
17//!  let server = firetrap::Server::with_root(std::env::temp_dir());
18//!  # if false { // We don't want to actually start the server in an example.
19//!  server.listen("127.0.0.1:2121");
20//!  # }
21//! }
22//! ```
23
24#[macro_use]
25extern crate log;
26extern crate failure;
27#[macro_use] extern crate failure_derive;
28#[cfg(test)]
29#[macro_use] extern crate pretty_assertions;
30
31/// Contains the `Server` struct that is used to configure and control a FTP server instance.
32pub mod server;
33pub use server::Server;
34
35pub(crate) mod commands;
36
37/// Contains the `Authenticator` trait that is used by the `Server` to authenticate users, as well
38/// as its various implementations.
39pub mod auth;
40
41/// Contains the `StorageBackend` trait that is by the `Server` and its various
42/// implementations.
43pub mod storage;