External authentication

You can use external modules (executables) to perform user authentication instead of using AfterLogic XMail Server 'mailusers.tab' lookups. Inside the userauth directory you'll find one directory for each service whose authentication can be handled externally (for now only POP3). Suppose We must authenticate 'USERNAME' inside 'DOMAIN', AfterLogic XMail Server first tries to lookup (inside userauth/pop3) a file named:

'DOMAIN.tab'

else:

'.tab'

If one of these files is found, AfterLogic XMail Server authenticates 'USERNAME' - 'DOMAIN' using that file. The authentication file is a TAB file (see at the proper section in this document) which has the given structure:

 "auth-action"[TAB]"command"[TAB]"arg-or-macro"[TAB]...[NEWLINE]

Each argument can be a macro also (see [MACRO SUBSTITUTION]):

USER

the USERNAME to authenticate

DOMAIN

the DOMAIN to authenticate

PASSWD

the user password

PATH

user path

The values for 'auth-action' can be one of:

item userauth

executed when user authentication is required

useradd

executed when a user need to be added

useredit

executed when a user change is required

userdel

executed when a user deletion is required

domaindrop

executed when all domain users need to be deleted

The first line that stores the handling command for the requested action is executed as:

 command arg0 ... argN

that must return zero if successful. Any other exit code is interpreted as authentication operation failure, that. in 'userauth' case, means such user is not authenticated.

If the execution of the command fails for system reasons (command not found, access denied, etc ...), then the user is not authenticated.

If none of this file's id are found, then usual authentication is performed ('mailusers.tab'). The use of external authentication does not avoid the presence of the user entry in 'mailusers.tab'.

[top]