rbldns-data

## Name

rbldns-data — compile the database used by rbldns

## Synopsis

`rbldns-data`

## Description

rbldns-data compiles a database in source form, in the file `data`, into a compiled form, in the file `data.cdb`, that is used by rbldns(1). The compiled database in `data.cdb` is a Bernstein Constant Database file.

rbldns-data updates `data.cdb` atomically, building a replacement in `data.cdb.tmp` and atomically renaming that replacement into place when it has completely and successfully built it it and written it to disc. So you can use it safely while rbldns(1) is running.

## Data format

Trailing whitespace is removed from all lines, then all non-empty lines are recognized as follows:

`#`comment``

  Comments are ignored.

`:`addr`:`message``

  A record DNS queries are to be answered with `addr`. TXT record DNS queries are to be answered with `message`.

  For example:

      :127.0.0.2:See http://rbl.example.com/why/$

``ip``

  The IP address `ip` is on the RBL blacklist/whitelist.

``ip`/`n``

  All IP addresses that share the first `n` bits of `ip` are on the RBL blacklist/whitelist. This is CIDR notation. `n` must be at least 8; and all bits of `ip` past the `n`th must be 0.

  For example:

      203.0.113.0/24

  means all `203.0.113.*` addresses.

## History

rbldns-data was originally part of Daniel J. Bernstein's djbdns toolset in 2000.

## Author

Original code and documentation by Daniel J. Bernstein. Documentation modernizations by Jonathan de Boyne Pollard.