
Installation:

Install libsdb. See http://siag.nu/libsdb/

Get the proftpd source from www.proftpd.org.

Unpack the proftpd source.

Copy mod_sql_sdb.c into proftpd's contrib directory.

Run configure like this, noting the backticks and quotes:
CFLAGS="`sdb-config --cflags`" \
LDFLAGS="`sdb-config --libs`" \
./configure --with-modules=mod_sql:mod_sql_sdb

Otherwise follow the installation instructions for proftpd as usual.
The documentation for mod_sql is in the contrib directory and applies
to mod_sql_sdb.

---

Add these lines to proftpd.conf:

#SQLConnectInfo    Any sdb url, examples:
SQLConnectInfo    oracle:uid=ulric/password@orasol
#SQLConnectInfo    sqlite:db=/path/to/db
SQLUserInfo       ftpuser username password userid groupid homedir shell
SQLMinID          1000
SQLMinUserGID     1000
SQLDefaultUID     1000
SQLAuthTypes      Plaintext
SQLAuthenticate   users

And create the user table like this:

create table ftpuser (
	username varchar(30) unique not null,
	password varchar(30) not null,
	userid integer,
	groupid integer,
	homedir varchar(255),
	shell varchar(255)
);

Example user:

insert into ftpuser values ('testuser','testpw',1000,1000,'/tmp','/bin/sh');

