chkuser 2.0 FAQ - Enabling chkuser
This page contains questions and answers relative to how to enable or
disable chuser checking.
Questions and answers
I have a standard installation, and chkuser seems not to work;
what am I doing wrong?
First, run patched qmail-smtpd manually (as root) and
check if chkuser works this way.
$ ./qmail-smtpd mail from
<wrong_sender> mail from <right_sender> rcpt
to: <fake_user@your_domain> rcpt to:
<real_user@your_domain>
If it does not work, check if any domain has bouncing
enabled. You may do this using qmailadmin, or you may set bouncing by
yourself:
| /vpopmail/bin/vdelivermail '' bounce-no-mailbox
If it does work, then you must check carefully how
qmail-smtpd is started; check carefully running instructions at:
Chkuser 2.0 -
running qmail-smtpd
How to enable chkuser always, for all domains?
Enable #define CHKUSER_ALWAYS_ON and
recompile your qmail.
Install new qmail-smtpd. That's all.
This #define will override any other #define.
I'ld like to enable or disable chkuser for all the system
without recompiling each time. How to make that?
Enable
#define CHKUSER_STARTING_VARIABLE "CHKUSER_START" and
recompile your qmail.
Then place the
environment variable CHKUSER_START in your qmail-smtpd
starting scripts or inside tcp.smtp, giving it the appropriate value:
- NONE : chkuser will NOT work
- ALWAYS : chkuser will ALWAYS work
- DOMAIN : chkuser will work depending on domain's bouncing
In this way you may change easily default behaviou of
chkuser.
If no variable is found, or variable is empty,
chkuser will NOT work.
I have more qmail-smtpd running on different IP addresses, and
I want to enable chkuser only on the external smtp server. How can I do?
Enable
#define CHKUSER_STARTING_VARIABLE "CHKUSER_START" and
recompile your qmail.
Then place the
environment variable CHKUSER_START in your qmail-smtpd
starting scripts, giving the appropriate value to the variable for each
starting script:
- NONE : chkuser will NOT work
- ALWAYS : chkuser will ALWAYS work
- DOMAIN : chkuser will work depending on domain's bouncing
If no variable is found, or variable is empty, chkuser
will NOT work.
I don't use vdelivermail. How can I still enable chkuser per
single domain?
You have two possibilities:
- With standard settings, modify .qmail-default according to your
needs, then add a comment line like
# bounce-no-mailbox at beginning of file.
chkuser will work if "bounce-no-mailbox" is found within leading 1023
characters.
- uncomment
#define CHKUSER_SPECIFIC_BOUNCING ".qmailchkuser-bouncing",
set you specific custom file name if you don't like ".qmailchkuser-bouncing",
and recompile and install qmail-smtpd.
Create ".qmailchkuser-bouncing" in
domain's dir. Now chkuser will execute checking if that file is found in
domain's dir. Be carefull, that file must be read by vpopmail
user!
I can't use "bounce-no-mailbox" in my .qmail-default. How do I
change this string?
Simply edit chkuser_settings.h and modify
#define CHKUSER_BOUNCE_STRING "bounce-no-mailbox"
writing your appropriate string.
Recompile and reinstall qmail-smtpd. |