CHECKRECIPIENT can be also be used to reject mails for inactive users, overquota users and users who do not have the privilege to receive mails. CHECKRECIPIENT can be enabled by setting the environment variable CHECKRECIPIENT to one of the following values
- Reject the user if not present in IndiMail's MySQL database
- Reject the user if not present in IndiMail's MySQL database and recipients.cdb
- Reject user if not present in recipients.cdb
If the environment variable MAX_RCPT_ERRCOUNT is set qmail-smtpd will reject an email if in a SMTP session, the number of such recipients who do not exist, exceed MAX_RCPT_ERRCOUNT.
CHECKRECIPIENT also causes the RCPT TO command to be delayed by 5 seconds for every non-existent recipient, to make harvesting of email addresses difficult.
If you do not have large number of users
% su # echo 1 > /service/qmail-smtpd.25/variables/CHECKRECIPIENT # svc -d /service/qmail-smtpd.25 # svc -u /service/qmail-smtpd.25 # exit %