3.15.1 Database Formats

The version 6.0 runs the following database types (or formats):

dns

DNS database caches DNS lookups. The key consists of the lookup type and the actual lookup key, separated by a single space. The type can be one of ‘A’, ‘PTR’, ‘MX’. The value is an ASCII string built up of one or more fields, separated by a single space. The first field is always the expiration date for this record in seconds since the Epoch (00:00:00 UTC, January 1, 1970). The meaning of the rest of the fields depends on the lookup type as described in the following table:

A

Each field contains the next IP address corresponding to the lookup key. Notice, that currently (version 6.0) there can be at most one field here, but it may change in the future.

PTR

Each field contains a host name corresponding to the lookup key. Notice, that currently (version 6.0) there can be at most one field here, but it may change in the future.

MX

Each field contains a host name of an ‘MX’ record for the lookup key.

See DNS Cache Management, for more information of DNS cache database and its management.

cache

Cache database keeps the information about external emails, obtained using sender verification functions (see section Checking Sender Address). The key entry to this database is an email address or email:sender-ip string, for addresses checked using strict verification. The data its stores for each key are:

  1. Address validity. This field can be either success or not_found, meaning the address is confirmed to exists or it is not.
  2. The time when the entry was entered into the database. It is used to check for expired entries.

The ‘cache’ database has two expiration periods: a positive expiration period, that is applied to entries with the first field set to success, and a negative expiration period, applied to entries marked as not_found.

rate

The mail sending rate data, maintained by rate function (see section Rate limiting functions). A record consists of the following fields:

timestamp

The time when the entry was entered into the database.

interval

Interval during which the rate was measured (seconds).

count

Number of mails sent during this interval.

tbf

This database is maintained by tbf_rate function (see TBF). Each record represents a single bucket and consists of the following keys:

timestamp

Timestamp of most recent token, as a 64-bit unsigned integer (microseconds resolution).

expirytime

Estimated time when this bucket expires (seconds since epoch).

tokens

Number of tokens in the bucket (size_t).

greylist

This database is maintained by greylist function (see section Greylisting). Each record holds only the timestamp. Its semantics depends on the greylisting implementation in use (see greylisting types). In traditional implementation, it is the time when the entry was entered into the database. In Con Tassios implementation, it is the time when the greylisting period expires.