Jaslabs: High performance Software

High Performance Software

an ftp server written in PHP

By Justin Silverton

nanoFTPd is an ftp daemon written in php. as of version 4.2.0, php supports the command-line interface (stable since 4.3.0), which nanoFTPd relies on. nanoFTPd is modular, so it’s easy to add custom modules and other stuff, like different database interfaces (currently supports mysql and postgresql).

Features

  • user authentication via a database/textfile
  • mysql + posgresql support
  • passive mode
  • dynamic ip support
  • basic ftp commands
  • logging

Requirements

  • PHP 4.2.0 or above
  • A database server (mysql or postgres)
  • PHP extension: cli
  • PHP extension: sockets
  • PHP extension: posix

Note: for best performance, compile php with –disable-cgi

Configuring

before running nanoFTPD, you need to do the following:

1) change variables in config.php
2) change the first line of nanoftpd.php to the path of your php binary

Installing

installing is fairly straight forward. you only have to copy the whole directory (with subdirectories) into a directory of your choice… e.g. /usr/share/nanoftpd
(working on a better structure — e.g. config.php into /etc, nanoftpd.php into
/usr/sbin).

Download

You can download nanoftpd here

Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Digg
  • del.icio.us
  • DZone
  • Slashdot
  • StumbleUpon
  • Technorati

5 Comments so far

  1. PHP Devils » FTP server written in PHP March 5th, 2007 9:49 am

    […] Создан FTP-сервер, написанный на PHP, ― nanoFTPd. Это еще раз показывает, что PHP пригоден для решения различных задач. nanoFTPd имеет модульную структуру, поэтому без труда можно добавлять к нему свои модули и дополнительные модификации, например, поддержку различных баз данных. […]

  2. […] In a new post to the JSLabs blog today, Justin Silverton mentions a FTP server that’s been created entirely in PHP - nanoFTP. nanoFTPd is an ftp daemon written in php. as of version 4.2.0, php supports the command-line interface (stable since 4.3.0), which nanoFTPd relies on. nanoFTPd is modular, so it’s easy to add custom modules and other stuff, like different database interfaces (currently supports mysql and postgresql). […]

  3. PHPGeek » FTP Server Written in PHP March 14th, 2007 7:20 am

    […] I like seeing PHP get used outside of the LAMP stack and web applications. That’s because PHP works well in lots of other contexts as well. There’s been a web server written *in* PHP for a while. And, it looks like there’s now an FTP server written in PHP as well. […]

  4. latafanera.net March 14th, 2007 10:07 pm

    Servidor FTP escrit en php!…

    Després de veure el servidor web escrit en PHP (http://nanoweb.si.kz/), ara arriba el servidor de FTP escrit en PHP! Impressionant. Vist a http://www.phpgeek.com/wordpress/ftp-server-written-in-php/108/…

  5. […] Link nanoFTPd Link Nanoweb […]

Leave a reply