bley
is an intelligent greylisting daemon for Postfix (and Exim).
It uses various test (incl. RBL and SPF) to decide whether a sender should be greylisted or not, thus mostly eliminating the usual greylisting delay while still filtering most of the spam.
bley
is written in Python using the
Twisted framework. It uses
pyspf for SPF validation and
publicsuffix for checking
of domains against the PublicSuffix.org
database. Database interaction is implemented via
sqlite3 for SQLite,
psycopg2 for PostgreSQL and
MySQL-Python for MySQL.
Unpack the tarball (or clone the git tree), adjust bley.conf.template
,
rename it to bley.conf
and run ./bley
.
Unpack the tarball (or clone the git tree), run python setup.py build
followed by python setup.py install
, copy /etc/bley/bley.conf.template
to /etc/bley/bley.conf
, adjust it to your needs (see CONFIGURATION below)
and run /usr/bin/bley
.
Basically you just have to configure the database:
dbtype = pgsql for PostgreSQL, mysql for MySQL or sqlite3 for SQLite
dbhost = the host where the database runs on (usually localhost)
dbuser = the name of the database user
dbpass = the password of the database user
dbname = the name (or path in case of SQLite) of the database
After that you can point your Postfix to bley
as a
policy server by
adding check_policy_service inet:127.0.0.1:1337
to your
smtpd_recipient_restrictions
in main.cf
.
bley
will be working now, but you probably would like to tune it more
for your needs (esp. the used DNWLs and DNSBLs, the greylisting times
and the hit thresholds).