other versions
- wheezy 0.63.0-6+b1
- jessie 0.66.1-1+b1
- testing 0.66.4-9
- unstable 0.66.4-9
- experimental 0.67.0-1
| AUTH_LOGIN(3) | Double Precision, Inc. | AUTH_LOGIN(3) |
NAME¶
auth_login - Validate a userid and passwordSYNOPSIS¶
#include <courierauth.h>
int
rc=auth_login(const char *service,
const char *userid,
const char *password,
int (*callback_func)(struct authinfo *, void *),
void *callback_arg);
DESCRIPTION¶
RETURNS¶
struct authinfo {
const char *sysusername;
const uid_t *sysuserid;
gid_t sysgroupid;
const char *homedir;
const char *address;
const char *fullname;
const char *maildir;
const char *quota;
const char *passwd;
const char *clearpasswd;
const char *options;
} ;
The authenticated login ID.
sysusername
The authenticated account´s userid and
groupid can be looked up in the password file using address. If this field is
NULL, obtain the userid and the groupid from sysuserid and sysgroupid.
sysuserid
Account´s numeric groupid. sysgroupid is
only used when sysusername is NULL.
fullname
This is the account´s full name. This
field is optional, it may be NULL.
homedir
The account´s home directory. This field
cannot be NULL.
maildir
The pathname to the account´s mailbox.
This field is optional, it can be NULL in which case the default location is
assumed.
quota
Optional maildir quota on the account´s
mailbox (and NULL if no quota is set).
passwd
The account´s encrypted password, if
available. If the account has a cleartext password defined, this field can be
set to NULL. The encrypted password can take several formats:
clearpasswd
•A traditional triple-DES crypted
password, or a MD5+salt-hashed password, as used in Linux.
• “{MD5}” followed by a
base64-encoded MD5 hash of the password.
• “{SHA}” followed by a
base64-encoded SHA1 hash of the password.
The account´s cleartext password, if
available. If the account has an encrypted password defined, this field can be
set to NULL.
options
A comma-separated list of miscellaneous
account options. See below for more information.
Account options¶
Depending on the configuration of the Courier authentication library, accounts may have individual options associated with them. If the authentication library configuration does not implement account options, the option string will be NULL. Otherwise it will be a comma-separated list of “ option= value” settings.If "n" is 1, IMAP access to this
account should be disabled.
disablepop3= n
If "n" is 1, POP3 access to this
account should be disabled.
disablewebmail= n
If "n" is 1, webmail access to this
account should be disabled.
disableshared= n
If "n" is 1, this account should not
have access to shared folders or be able to share its own folders with other
people.
group= name
This account is a member of access group
name. Instead of granting access rights on individual mail folders to
individual accounts, the access rights can be granted to an access group
“name”, and all members of this group get the specified access
rights.
The access group name “administrators” is a reserved group. All
accounts in the administrators group automatically receive all rights to all
accessible folders.
Note
This option may be specified multiple times to specify that the account belongs
to multiple account groups.
sharedgroup= name
Append "name" to the name of the top
level virtual shared folder index file. This setting restricts which virtual
shared folders this account could possibly access (and that´s on top of
whatever else the access control lists say). See the virtual shared folder
documentation for more information.
For technical reasons, group names may not include comma, tab, "/" or
"|" characters.
SEE ALSO¶
NOTES¶
- 1.
- authlib(3)
authlib.html
auth_generic.html
auth_getuserinfo.html
auth_enumerate.html
auth_passwd.html
auth_getoption.html
| 08/23/2008 | Double Precision, Inc. |