SPFBL.net · Documentation

MTA Clients

An MTA client is a mail server of yours that queries SPFBL for every message it receives. Irondome installs this integration on the server, and the registration in your account is automatic.

How it works

During the SMTP conversation, the mail server asks SPFBL about each message: first the envelope (IP, HELO, sender and recipient, the SPF query), then the header and content (the HEADER query). SPFBL answers whether the message should be accepted, held or refused, and the server applies the answer. Held messages show up in the panel history, where they can be released.

Each query goes over HTTPS with an access key of your account and the server hostname. The key ties the server to your account, and the hostname is how it shows up on the MTA Clients screen.

Installation

  1. Create an access key on the MTA Clients screen itself. The authenticator code (TOTP) is required.
  2. Run the installation command shown on the screen, as root, on the mail server. It checks the server compatibility and shows a menu with the options.
  3. Enter the key when the installer asks for it. It checks the key and the server hostname before changing any configuration.
  4. Check the MTA Clients screen. The server shows up as soon as it makes its first query.
The key is shown only once, when it is created. Do not send the key by email or chat; if it leaks, revoke it in Access keys and create another one.

Supported servers

The installer detects the control panel and the mail server. Today it installs on:

  • cPanel/WHM and DirectAdmin, with the panel's Exim;
  • Pure Exim (no panel) on Debian and Ubuntu, with Exim 4.92 or newer;
  • iRedMail and CWP, with an Exim on port 25 in front of Postfix.

On any other combination, the installer changes nothing and shows the server data. Send those lines to support so we can evaluate the compatibility.

Access key

  • We recommend one key per server: if a server is compromised, you revoke only its key, without stopping the others.
  • The key does not expire, but it is revoked after 180 days without use.
  • The screen shows which key each server is using. A revoked key is marked; the server using it gets refusals and lets messages pass unfiltered until it gets a new key (run the installer and use the key change option).

Server hostname

The server is identified by the machine's full hostname (FQDN), and SPFBL uses that name to send the server the release signals for held messages. That is why the hostname must:

  • have an A (IPv4) and/or AAAA (IPv6) record in DNS with the IP the server queries from;
  • not be a generic provider name (like ip-10-0-0-1.provider.com);
  • be on a public IP, not private or reserved.

Each query updates the registration: current IP, key and date. If you change the machine hostname, the client is renamed and the screen shows the old name and the date of the change. If the same hostname starts querying with the key of another account, the client moves to that account.

Refused servers

When the hostname fails validation, the server shows up under Refused servers, with the reason: no A/AAAA record, record without the server IP, generic name, reserved IP or invalid hostname. Meanwhile, that server's messages pass without filtering, so no email is lost, and the reason is logged on the mail server.

Fix the DNS or the machine hostname. SPFBL checks again every 10 minutes, and the server goes back to the normal list by itself. You get a notice by email, at most one a day, and in the panel bell.

The client list

For each server, the screen shows the hostname, the known IPs, the last query and the key used. Servers with no query for 7 days leave the list by themselves, with an email alert, and come back automatically if they query again.

With active billing, the Add to RBL Monitoring button, on each server, puts its hostname into monitoring with one click. The button shows while the hostname is not there, even if the server's IP is already monitored: only the FQDN follows IP changes. Legacy servers, without a hostname, do not have the button.

Legacy clients

Servers installed with old Irondome versions were registered by IP and query without a key. They are marked as legacy. For security, update Irondome on those servers: run the same installation command and choose Update. After the update, the server shows up by hostname, with the key.

Connection monitoring

Servers with an access key are monitored on both sides. Legacy clients, without a key, are left out.

  • By SPFBL: when a server stops querying outside its usual pace, SPFBL sends a signal through port 25, the same channel of the release signals. If the server answers with a query, it was only silence and nothing happens. If it does not answer, you get an email: no path to SPFBL (the server receives email but cannot query; messages pass unfiltered) or no answer on port 25 (the server may be down). When it queries again, another notice comes.
  • On the server itself: every hour, spfbl monitor tests the query. If it fails in two checks in a row (about 1 hour), outside scheduled maintenance, the postmaster of the machine gets a local email with the diagnosis; the notice repeats once a day and another one comes on recovery. This email arrives even when the server reaches nothing outside.

To investigate, run spfbl diagnose on the server. It changes nothing and checks, in order: /etc/hosts, each DNS server alone, the resolution of the SPFBL name, the HTTPS connection over IPv4 and IPv6, the clock, the proxy and the outgoing firewall (CSF) and the query with the access key. At the top, it shows the SPFBL status on status.spfbl.net (online or under scheduled maintenance); at the end, the probable causes. Under scheduled maintenance, a query failure is expected and goes away by itself. The same diagnosis exists in the installer (spfbl.irondome.sh diagnose) and is offered by itself when the installation or the update fails.

You also get an email when a server is registered (first query with a key of your account), when it starts querying with the key of another account and when Irondome is uninstalled from it.

Removal

The Remove button becomes available after 1 hour without queries from the server, so a server in use is not removed by mistake. Removal requires the authenticator code (TOTP) and sends an email alert. If the server queries again, it is registered again automatically; to stop for good, uninstall Irondome on it or revoke the key.

Billing

  • MTA clients: each server that queries in the cycle is billed once, legacy ones included. Removing the server mid-cycle does not remove the amount already charged.
  • SPF queries and HEADER queries: billed per thousand queries, as shown on the Billing screen.
  • Other items, such as firewall generations and complaints, also come from your servers' queries.

Emails arriving through the MX Gateway are billed the same way, as if the SPFBL.net MX servers were an MTA client of your account.

Update and uninstall

The same installation command also updates and uninstalls Irondome, through the menu. Uninstalling restores the original mail server configuration and removes only what Irondome installed. Before removing anything, it tells SPFBL: the server leaves the MTA clients at once, without the 1-hour wait, and you get the uninstallation notice. The amount already charged in the cycle stays on the invoice.