Skip to content

uFTP server

uFTP is an open source FTP and FTPS server written in C for Linux and other POSIX systems. It is one binary and one configuration file, it is easy to build, and it runs from tiny embedded systems to busy servers.

Quick start Source code on GitHub

Why uFTP

  • Simple. One program, one configuration file (uftpd.cfg), every option explained in the file.
  • FTP and FTPS. Explicit TLS (AUTH TLS) on the control and the data connections, passive and active mode, IPv4 and IPv6.
  • Light. One process with a few threads, not one process per client. Memory use is predictable: see Configuration.
  • Portable. Plain C. It runs on x86, x64, ARM and other architectures,
  • Careful by default. Hashed passwords, permissions and speed limits for each user, limits per address and per account, login lock-out, a free space guard, and a ready, tested filter for fail2ban.
  • Your users, your way. Users in a file of their own, or from a database, LDAP or an API through an authentication hook, without restarting the server.
  • Useful for backups. Checksums and MFMT so that lftp and others move only what changed, and SITE RUN to start a backup or a database dump on the server. See the recipes.
  • Without root, in a container. A hardened systemd unit and a Docker image that does not run as root; see Run without root.
  • Tidy to stop and quiet. SIGTERM lets the transfers in progress end; with the log off the server writes nothing (for devices with no place to write).
  • Easy to watch. Health pages, metrics for Prometheus, uftpctl and uFTP --check.
  • Tested. An automatic test suite, fuzzing, and builds with AddressSanitizer and ThreadSanitizer.
  • Open. MIT license: free for personal and commercial use, and you can reuse the code.

Why another FTP server?

I have worked with embedded Linux for decades, and one of the most annoying parts is configuring servers so that they match the application. Most FTP servers are hard to compile, hard to configure and hard to understand. uFTP is an easy alternative to the classic heavy servers: one portable program, one configuration file that can sit in the directory you start the server from or in /etc/, and only a few settings to make. That makes it a good fit for small distributions and even for an initramfs, where a server is needed and a full one is too much.

Where to go next

I want to... Read
Try it in five minutes Quick start
Build and install it Installation
Use FTPS TLS and certificates
Know every option Configuration
Run it behind a router Behind a NAT or a firewall
Run it in Docker or as a service Docker, systemd, Run without root
Give each user their own rights and limits Configuration
Take users from a database or LDAP Authentication hook
Back up or sync with lftp, curl, rclone Recipes, Run scripts
See what the server is doing Watch the server
Fix a problem Troubleshooting

Source code: https://github.com/kingk85/uFTP