Skip to content

indimail control.5

Manvendra Bhangui edited this page Feb 25, 2024 · 7 revisions

NAME

indimail-control - indimail configuration files

INTRODUCTION

You can change the behavior of the indimail-mta system by modifying indimail-mta's control files in /etc/indimail/control. You can set the environment variable CONTROLDIR to make indimail-mta look for control files in a different directory.

indimail-mta can survive with just one control file, me, containing the fully-qualified name of the current host. This file is used as the default for other hostname-related control files.

Comments are allowed in accesslist, authdomains, badext, badextpatterns, badhelo, badmailfrom, badmailpatterns, bindroutes, blackholedrcpt, blackholedrcptpatterns, blackholedsender, blackholedpatterns, badrcptto, badrcptpatterns, bodycheck, chkrcptdomains, chksenderdomains, dkimkeys, domainbindings, earlytalkerdroptime, etrnhosts, filterargs, goodrcptto, goodrcptpatterns, hostaccess, locals, localdomains, nodnscheck, percenthack, qmqpservers, relaymailfrom, relayclients, relaydomains, removeheaders, recipients, rejectspam, rcpthosts, signatures, smtproutes, qmtproutes, redirectremote, spamfilter, spamredirect, spamignore, spamignorepatterns, from.envrules, fromd.envrules, rcpt.envrules, auth.envrules, domainqueue, signaturedomains, nosignaturedomains, badhost, badip, mailarchive, srs_secrets, removeheaders, envheaders, logheaders, and virtualdomains. Trailing spaces and tabs are allowed in any control file.

The following control files can also be specified in cdb format or be in MySQL.

authdomains, badhelo, badext, badmailfrom, badrcptto, blackholedsender, blackholedrcpt, chkrcptdomains, chksenderdomains, goodrcptto, relaymailfrom, spamignore, greylist.white, tlsa.white, tlsadomains, morercpthosts, and badip.

To use the cdb format, the control files should be converted to cdb using qmail-cdb(8) and have a .cdb extension. To have the control files in MySQL, you should have the control file with a .sql extension and a colon separated list of paramaters for connecting to MySQL specified in the file. If the files are present in all the 3 formats, cdb file will be used.

The parameters are as given below.

db_server_ip:db_user:db_password:db_name:table_name.

Having the following entry in badmailfrom.sql

localhost:indimail:ssh-1.5-:qmail:my_badmailfrom

specifies that entries for  badmailfrom should  be  checked in the MySQL
table my_badmailfrom on localhost. The username and password for
connecting to MySQL is indimail and ssh-1.5- and the database
name to use is qmail.

For database connection to MySQL, one can define MYSQL_LIB environment variable or have the control file mysql_lib. e.g.

  MYSQL_LIB= /usr/lib64/mysql/libmysqlclient.so.21.0.15

Environment variable takes precedence over the control file.

The following control files can have regular expressions for match if QREGEX environment variable is defined

badhelo, badhost, badip, blackholedsender, blackholedrcpt, badmailfrom, spamignore, relaymailfrom, authdomains, badrcptto, chkrcptdomains, chksenderdomains, badext, goodrcptto, and accesslist.

Once you define QREGEX, the corresponding pattern file gets disabled (e.g. badhelopatterns, badhostpatterns, badmailfrompatterns, etc).

The following table lists all control files other than me. See the corresponding man pages for further details.

control	default	used by

accesslist (none) qmail-smtpd
authdomains (none) qmail-smtpd
badhelo (none) qmail-smtpd
badhost (none) qmail-smtpd
badmailfrom (none) qmail-smtpd
badmailpatterns (none) qmail-smtpd
goodrcptto (none) qmail-smtpd
goodrcpttpatterns (none) qmail-smtpd
domainqueue (none) qmail-smtpd
auth.envrules (none) qmail-smtpd
from.envrules (none) qmail-smptd
fromd.envrules (none) spawn-filter
rcpt.envrules (none) spawn-fliter
badext (none) qscanq-stdin
badextpatterns (none) qscanq-stdin
badrcptto (none) qmail-smtpd
badrcptpatterns (none) qmail-smtpd
blackholedsender (none) qmail-smtpd
blackholedpatterns (none) qmail-smtpd
blackholedrcpt (none) qmail-smtpd
blackholedrcptpatterns (none) qmail-smtpd
blackholedsender (none) qmail-smtpd
bouncefrom MAILER-DAEMON qmail-send
bouncehost me qmail-send
bouncemessage QSBMF qmail-send
bouncesubject failure notice qmail-send
bouncemaxbytes 50000 qmail-send
doublebounceto postmaster qmail-send
doublebouncehost me qmail-send
doublebouncemessage QSBMF qmail-send
doublebouncesubject failure notice qmail-send
concurrencylocal 10 qmail-send
concurrencyremote 20 qmail-send
msgqueuelen 10 qscheduler
msgqueuesize 81920 qscheduler
defaultdomain me qmail-inject
defaultdelivery (none) qscheduler
defaulthost me qmail-inject
dnsbllist (none) qmail-smtpd
databytes $DATABYTES qmail-smtpd
envnoathost me qmail-send
extraqueue (none) qmail-queue
quarantine (none) qmail-queue
helohost me qmail-remote
holdlocal 0 qmail-send
holdremote 0 qmail-send
todointerval (none) todo-proc
idhost me qmail-inject
localiphost me qmail-smtpd
outgoingip me qmail-remote
bindroutes (none) qmail-remote
domainbindings me qmail-remote
rcpthosts (none) qmail-smtpd
morercpthosts (none) qmail-smtpd
locals me qmail-send, qmail-smtpd
maxdeliveredto 0 qmail-local
localdomains (none) qmail-local
virtualdomains (none) qmail-send
etrnhosts (none) qmail-smtpd
nodnscheck $NODNSCHECK qmail-smtpd
percenthack (none) qmail-send
plusdomain me qmail-inject
qmqpservers (none) qmail-qmqpc
chkrcptdomains (none) qmail-smtpd
chksenderdomains (none) qmail-smtpd
queuelifetime 604800 qmail-send
relayclients $RELAYCLIENT qmail-smtpd
relaydomains $RELAYCLIENT qmail-smtpd
relaymailfrom (none) qmail-smtpd
recipients (none) qmail-smtpd
smtpgreeting me qmail-smtpd
smtproutes (none) qmail-remote
qmtproutes (none) qmail-remote
redirectremote (none) rd-remote
spfbehavior 0 qmail-smtpd
spfexp (default) qmail-smtpd
spfguess (none) qmail-smtpd
spfrules (none) qmail-smtpd
moreipme (none) qmail-smtpd
notipme (none) qmail-smtpd
maxrecipients $MAXRECIPIENTS qmail-smtpd
maxhops (none) qmail-smtpd
tarpitcount $TARPITCOUNT=0 qmail-smtpd
tarpitdelay $TARPITDELAY=5 qmail-smtpd
timeoutconnect 60 qmail-remote
timeoutremote 1200 qmail-remote
timeoutsmtpd 1200 qmail-smtpd
timeoutread 4 qmail-smtpd
timeoutwrite 4 qmail-smtpd
certs/clientca.pem (none) qmail-smtpd
certs/clientcert.pem (none) qmail-remote
certs/dh1024.pem (none) qmail-smtpd
certs/dh512.pem (none) qmail-smtpd
certs/rsa512.pem (none) qmail-smtpd
certs/servercert.pem (none) qmail-smtpd
certs/tlsclients (none) qmail-smtpd
certs/tlsclientciphers (none) qmail-remote
certs/tlshosts/FQDN.pem (none) qmail-remote
certs/tlsserverciphers (none) qmail-smtpd
certs/tlsservermethod (none) qmail-smtpd
certs/tlsclientmethod (none) qmail-remote
certs/notlshosts/ (none) qmail-remote
notlshosts (none) qmail-remote
tlsadomains (none) qmail-remote, qmail-daned
originipfield (none) qmail-queue
filterargs (none) spawn-filter
globalspamredirect (none) qmail-multi
spamfilter (none) spawn-filter
spamignore (none) qmail-smtpd, spawn-filter
spamignorepatterns (none) qmail-smtpd, spawn-filter
spamredirect (none) spawn-filter
rejectspam (none) spawn-filter
hostaccess (none) qmail-smtpd
signatures (none) qmail-smtpd
bodycheck (none) qmail-smtpd
qregex (none) qmail-smtpd, qmail-send, slowq-send, qmta-send, uacl
earlytalkerdroptime (none) qmail-smtpd
signaturedomains (none) qmail-dkim
nosignaturedomains (none) qmail-dkim
batvkey (none) qmail-remote, qmail-smtpd
batvkeystale 7 qmail-smtpd
nosignremote (none) qmail-remote, qmail-smtpd
nosignlocals (none) qmail-remote
srs_domains (none) qmail-smtpd, qmail-local, qmail-send, slowq-send,
		qmta-send, qmail-inject, condredirect, forward,
		autoresponder, filterit, srsfilter
srs_secrets (none) qmail-smtpd, qmail-local, qmail-send, slowq-send,
		qmta-send, qmail-inject, condredirect, forward,
		autoresponder, filterit, srsfilter
srs_maxage 7 qmail-smtpd, qmail-local, qmail-send, slowq-send,
		qmta-send, qmail-inject, condredirect, forward,
		autoresponder, filterit, srsfilter
srs_hashlength 4 qmail-smtpd, qmail-local, qmail-send, slowq-send,
		qmta-send, qmail-inject, condredirect, forward,
		autoresponder, filterit, srsfilter
srs_hashmin 4 qmail-smtpd, qmail-local, qmail-send, slowq-send,
		qmta-send, qmail-inject, condredirect, forward,
		autoresponder, filterit, srsfilter
srs_separator = qmail-smtpd, qmail-local, qmail-send, slowq-send,
		qmta-send, qmail-inject, condredirect, forward,
		autoresponder, filterit, srsfilter
srs_alwaysrewrite 0 qmail-smtpd, qmail-local, qmail-send, slowq-send,
		qmta-send, qmail-inject, condredirect, forward,
		autoresponder, filterit, srsfilter
servicedir.conf /service svctool

Defaultvalues following a $ sign (ie. $RELAYCLIENT) depend on the corresponding environment variable.

SEE ALSO

qmail-inject(8), spawn-filter(8), qmail-qmqpc(8), qmail-queue(8), qmail-remote(8), qmail-send(8), qmail-showctl(8), qmail-smtpd(8), qmail-remote(8), qscanq-stdin(8),

Clone this wiki locally