|
Project Information
Featured
Links
|
Python FTP server library (pyftpdlib) AboutPython FTP server library provides a high-level portable interface to easily write asynchronous FTP servers with Python. pyftpdlib is currently the most complete RFC-959 FTP server implementation available for Python programming language. It is used in projects like Google Chromium and Bazaar and included in Debian, Fedora and FreeBSD package repositories. Quick linksFeatures- FTPS (FTP over TLS/SSL).
- Support for recent FTP commands such as MLSD, MLST, EPSV and EPRT (RFC-3659).
- Support for virtual users and virtual filesystem.
- IPv6 (RFC-2428) support.
- Bandwidth throttling.
- Per-user permissions configurability.
- Fast (uses sendfile(2) system call for uploads) and scalable.
- Compact: main library is distributed as a single stand-alone module (ftpserver.py).
- Portable:
- Entirely written in pure Python.
- Extremely flexible system of "authorizers" able to manage both "virtual" and "real" users on on both Windows and UNIX.
- Works with Python from 2.4 to 2.7.
PerformancesDepite being written in an intepreted language, pyftpdlib seems to have transfer rates comparable or superior to most common UNIX FTP servers. It also scales better since whereas vsftpd and proftpd uses multiple processes to achieve concurrency, pyftpdlib will only use one process and handle concurrency asynchronously (see the C10K problem). Here are some benckmarks made against my Linux 3.0.0 box, Intel core-duo 3.1 Ghz: | benchmark type | pyftpdlib 0.7.0 | proftpd 1.3.4rc2 | vsftpd 2.3.2 | | STOR (client -> server) | 508.80 MB/sec | 609.22 MB/sec | 648.48 MB/sec | | RETR (server -> client) | 1635.14 MB/sec | 1313.77 MB/sec | 1505.18 MB/sec | | 200 concurrent clients (connect, login) | 0.22 secs | 7.53 secs | 14.54 secs | | 200 concurrent clients (RETR 10M file) | 2.33 secs | 2.76 secs | 2.88 secs | | 200 concurrent clients (STOR 10M file) | 3.83 secs | 6.39 secs | N/A | | 200 concurrent clients (quit) | 0.02 secs | 0.23 secs | 0.01 |
Quick start>>> from pyftpdlib import ftpserver
>>> authorizer = ftpserver.DummyAuthorizer()
>>> authorizer.add_user("user", "12345", "/home/user", perm="elradfmw")
>>> authorizer.add_anonymous("/home/nobody")
>>> handler = ftpserver.FTPHandler
>>> handler.authorizer = authorizer
>>> address = ("127.0.0.1", 21)
>>> ftpd = ftpserver.FTPServer(address, handler)
>>> ftpd.serve_forever()
Serving FTP on 127.0.0.1:21
[]127.0.0.1:2503 connected.
127.0.0.1:2503 ==> 220 Ready.
127.0.0.1:2503 <== USER anonymous
127.0.0.1:2503 ==> 331 Username ok, send password.
127.0.0.1:2503 <== PASS ******
127.0.0.1:2503 ==> 230 Login successful.
[anonymous]@127.0.0.1:2503 User anonymous logged in.
127.0.0.1:2503 <== TYPE A
127.0.0.1:2503 ==> 200 Type set to: ASCII.
127.0.0.1:2503 <== PASV
127.0.0.1:2503 ==> 227 Entering passive mode (127,0,0,1,9,201).
127.0.0.1:2503 <== LIST
127.0.0.1:2503 ==> 150 File status okay. About to open data connection.
[anonymous]@127.0.0.1:2503 OK LIST "/". Transfer starting.
127.0.0.1:2503 ==> 226 Transfer complete.
[anonymous]@127.0.0.1:2503 Transfer complete. 706 bytes transmitted.
127.0.0.1:2503 <== QUIT
127.0.0.1:2503 ==> 221 Goodbye.
[anonymous]@127.0.0.1:2503 Disconnected.Contribute / DonateIf you think pyftpdlib is worth a donation you can send me (Giampaolo RodolĂ ) some money by clicking the banner below:
If you want to help or just give suggestions subscribe to the discussion mailing list or feel free to contact authors at the following addresses: | Name | Country | E-mail | Description | | Giampaolo Rodola' | Turin (Italy) | g.rodola at gmail dot com | Original pyftpdlib author and main maintainer. | | Jay Loden | New Jersey (USA) | jloden at gmail dot com | OSX development/testing | | Janos Guljas | | janos at janos.in dot rs | Debian package maintainer | | Silas Sewell | Denver (USA) | silas at sewell dot ch | Fedora package maintainer | | Li-Wen Hsu | Taiwan | lwhsu at freebsd dot org | FreeBSD package maintainer |
Feedbacks and suggestions are greatly appreciated as well as new testers and coders willing to join the development. For any bug report, patch proposal or feature request, add an entry into the Issue Tracker. In case you're using pyftpdlib into a software or website of yours, please update the pyftpdlib Adoptions List by adding a comment in the Wiki. Timeline- 2012-01-25: version 0.7.0 released.
- 2011-12-01: pyftpdlib included in feitp-server project.
- 2011-09-26: pyftpdlib included in ftpmaster project.
- 2011-07-09: pyftpdlib included in bftpd project.
- 2011-07-09: pyftpdlib included in fastersync project.
- 2011-01-31: pyftpdlib included in put.io FTP connector project.
- 2011-01-24: version 0.6.0 released.
- 2010-12-14: added donations.
- 2010-08-24: pyftpdlib included in peerscape project.
- 2010-07-15: pyftpdlib included in Faetus project.
- 2010-07-11: pyftpdlib included in Pyfilesystem project.
- 2010-06-28: pyftpdlib has been packaged for Debian
- 2010-04-28: pyftpdlib included in sierramodulepos project.
- 2010-03-20: http://www.smartfile.com uses pyftpdlib.
- 2010-01-13: pyftpdlib included in zenftp project.
- 2009-12-26: pyftpdlib included in Symbian Python FTP server project.
- 2009-11-04: www.netplay.it uses pyftpdlib.
- 2009-11-04: www.adcast.tv uses pyftpdlib.
- 2009-11-04: www.bitsontherun.com uses pyftpdlib.
- 2009-11-02: pyftpdlib included in ftp-cloudfs project.
- 2009-09-14: version 0.5.2 released.
- 2009-08-10: pyftpdlib included in Imgserve project.
- 2009-07-22: pyftpdlib included in Plumi project.
- 2009-04-02: pyftpdlib RPM-packaged and ported on Fedora to make users can easily install on it via yum install pyftpdlib.
- 2009-03-28: pyftpdlib included in Bazaar project.
- 2009-02-23: pyftpdlib included in ShareFTP project.
- 2009-01-21: version 0.5.1 released.
- 2008-12-27: pyftpdlib included in Google Chromium, the open source project behind Google Chrome.
- 2008-12-27: pyftpdlib ported on GNU Darwin systems to make users can easily install on it.
- 2008-11-26: pyftpdlib included in OpenERP.
- 2008-10-26: pyftpdlib included in Python for OpenVMS as standard package.
- 2008-10-09: pyftpdlib included in Shareme project.
- 2008-09-20: version 0.5.0 released.
- 2008-08-10: pyftpdlib included in Manent project.
- 2008-05-16: version 0.4.0 released.
- 2008-04-09: pyftpdlib used as backend for gpftpd, an FTP server for managing files hosted on Google Pages.
- 2008-01-17: version 0.3.0 released.
- 2007-10-14: pyftpdlib included in Aksy project.
- 2007-09-17: version 0.2.0 released.
- 2007-09-08: pyftpdlib included as FarManager plug-in.
- 2007-03-06: pyftpdlib ported on FreeBSD systems to make users can easily install on it.
- 2007-03-07: version 0.1.1 released.
- 2007-02-26: version 0.1.0 released.
Statistics TrademarksSome famous trademarks which adopted pyftpdlib (complete list).
|