s/qmail:

NAME
SYNOPSIS
DESCRIPTION
USAGE
SECURITY
RETURN CODES
SEE ALSO

NAME

qmail-vmailuser - recipient validation

SYNOPSIS

qmail-vmailuser [ -cCMPU ] [ homedir ]

DESCRIPTION

qmail-vmailuser is a user existing validation PAM supporting VMailMgr and Vpopmail users for virtual domains. Invoked via qmail-smtpd’s recipient mechanism, it checks the existence of the recipient’s directory for the provisioned virtual users in /var/qmail/control/virtualusers.

qmail-vmailuser may consider three types of virtual user directories: -M The VirtualMgr, -P Vpopmail, and -U just a standard Unix virtual user. If none is given, all three cases are tested. Providing -C allows a case-sensitive evaluation of the user’s name, while -c (case-insensitive) is the default.

qmail-vmailuser’s default homedir is /home if not otherwise given.

qmail-vmailuser follows checkpassword’s interface specification evaluating the SMTP forwarding path (RCPT TO:) taken from discriptor 3 with a length of max 128 bytes.

The forwarding path vuser@domain is tokenized to determine the virtual user in /var/qmail/control/virtualusers given by domain in the first step and then validating for vuser the existance of (v)user’s directory in lower case while substituting dots by colons.

USAGE

qmail-vmailuser is called as PAM from qmail-smtpd’s control file /var/qmail/control/recipients:

domain|bin/qmail-vmailuser
*|bin/qmail-vmailuser -P

in case of Vpopmail.

Since homedir defaults mostly to /home, this argument can be omitted.

SECURITY

For successfull operation qmail-vmailuser requires to stat vuser’s directory though without reading it’s actual contents. Due to restrictions given by Vpopmail, qmail-vmailuser needs to belong to vpopmail:vchkpw or generally to be root-owned and ’sticky’.

RETURN CODES

If for the provided vuser@domain the user directory does exist qmail-vmailuser exits 0 otherwise 1. If qmail-vmailuser is misused, it may instead exit 2. If there is a temporary problem, qmail-vmailuser exits 111. In case qmail-vmailuser can’t read /var/qmail/control/virtualdomains it exits 110.

SEE ALSO

addresses(5), envelopes(5), qmail-send(8), qmail-smtpd(8), qmail-recipients(8), qmail-authuser(8).