All settings are environment variables, set in .env for Docker Compose. A wrong value stops EmailFilter at startup with a message naming the variable.
| Variable | Default | Notes |
|---|---|---|
EMAILFILTER_LISTEN |
:8000 |
Address and port to listen on. |
EMAILFILTER_API_KEY |
Required on every endpoint except /healthz when set. At least 16 characters. |
|
EMAILFILTER_RATE_LIMIT |
120 |
Requests per minute per client IP. 0 turns it off. |
EMAILFILTER_TRUST_PROXY |
Comma-separated IPs or CIDRs of reverse proxies allowed to set X-Forwarded-For. |
|
EMAILFILTER_ACCEPT_SCORE |
60 |
Lowest score that is accepted. |
EMAILFILTER_CHECK_TIMEOUT |
10s |
Longest time one check may take, network checks included. |
EMAILFILTER_SMTP_CHECK |
true |
Ask mail servers whether the mailbox exists. Turn off where port 25 is blocked. |
EMAILFILTER_SMTP_HELO |
hostname | Name sent in EHLO. Use a name with matching reverse DNS. |
EMAILFILTER_SMTP_FROM |
null sender <> |
Envelope sender of the SMTP check. |
EMAILFILTER_SMTP_TIMEOUT |
5s |
Per mail server. |
EMAILFILTER_DOMAIN_AGE_CHECK |
true |
Look up the registration date with RDAP and WHOIS. |
EMAILFILTER_NEW_DOMAIN_DAYS |
30 |
A domain younger than this is new_domain. |
EMAILFILTER_RECORD_CHECKS |
true |
Count checks per domain for reputation. |
EMAILFILTER_REPUTATION_MAX |
100000 |
Most domains kept in reputation; 0 is no limit. |
EMAILFILTER_DISPOSABLE_URL |
Download the disposable domains list from this URL at startup and then periodically. | |
EMAILFILTER_DISPOSABLE_REFRESH |
24h |
How often to download it. |
EMAILFILTER_POLICY_LISTEN |
Address for the Postfix policy service, for example :10040. Off when empty. |
|
EMAILFILTER_LISTS_DIR |
lists |
Folder with the list files. |
EMAILFILTER_SCORES_FILE |
config/scores.json |
Custom weights. |
EMAILFILTER_DATA_DIR |
data |
Folder for reputation.json. |
EMAILFILTER_LOG_LEVEL |
info |
debug, info, warn or error. |
The list files in lists/ have one entry per line; lines starting with # are ignored. disposable_domains.txt in this repository is updated every day from disposable-email-domains; git pull brings the new list and EmailFilter reloads it. Without a git checkout, set EMAILFILTER_DISPOSABLE_URL to that address instead.