[ Index ] |
PHP Cross Reference of DokuWiki |
[Source view] [Print] [Project Stats]
(no description)
File Size: | 703 lines (25 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
auth_plugin_authldap:: (14 methods):
__construct()
checkPass()
getUserData()
fetchUserData()
modifyUser()
isCaseSensitive()
retrieveUsers()
makeFilter()
filter()
constructPattern()
filterEscape()
openLDAP()
ldapSearch()
debug()
Class: auth_plugin_authldap - X-Ref
LDAP authentication backend__construct() X-Ref |
Constructor |
checkPass($user, $pass) X-Ref |
Check user+password Checks if the given user exists and the given plaintext password is correct by trying to bind to the LDAP server author: Andreas Gohr <andi@splitbrain.org> return: bool param: string $user param: string $pass |
getUserData($user, $requireGroups = true) X-Ref |
Return user info Returns info about the given user needs to contain at least these fields: name string full name of the user mail string email addres of the user grps array list of groups the user is in This LDAP specific function returns the following addional fields: dn string distinguished name (DN) uid string Posix User ID inbind bool for internal use - avoid loop in binding author: <evaldas.auryla@pheur.org> author: Stephane Chazelas <stephane.chazelas@emerson.com> author: Steffen Schoch <schoch@dsb.net> author: Andreas Gohr <andi@splitbrain.org> author: Trouble author: Dan Allen <dan.j.allen@gmail.com> return: array containing user data or false param: string $user param: bool $requireGroups (optional) - ignored, groups are always supplied by this plugin |
fetchUserData($user, $inbind = false) X-Ref |
return: array containing user data or false param: string $user param: bool $inbind authldap specific, true if in bind phase |
modifyUser($user, $changes) X-Ref |
Definition of the function modifyUser in order to modify the password return: bool true on success, false on error param: string $user nick of the user to be changed param: array $changes array of field/value pairs to be changed (password will be clear text) |
isCaseSensitive() X-Ref |
Most values in LDAP are case-insensitive return: bool |
retrieveUsers($start = 0, $limit = 0, $filter = []) X-Ref |
Bulk retrieval of user data author: Dominik Eckelmann <dokuwiki@cosmocode.de> return: array of userinfo (refer getUserData for internal userinfo details) param: int $start index of first user to be returned param: int $limit max number of users to be returned param: array $filter array of field/pattern pairs, null for no filter |
makeFilter($filter, $placeholders) X-Ref |
Make LDAP filter strings. Used by auth_getUserData to make the filter strings for grouptree and groupfilter author: Troels Liebe Bentsen <tlb@rapanden.dk> return: string param: string $filter ldap search filter with placeholders param: array $placeholders placeholders to fill in |
filter($user, $info) X-Ref |
return true if $user + $info match $filter criteria, false otherwise author: Chris Smith <chris@jalakai.co.uk> return: bool param: string $user the user's login name param: array $info the user's userinfo array |
constructPattern($filter) X-Ref |
Set the filter pattern author: Chris Smith <chris@jalakai.co.uk> return: void param: $filter |
filterEscape($string) X-Ref |
Escape a string to be used in a LDAP filter Ported from Perl's Net::LDAP::Util escape_filter_value author: Andreas Gohr return: string param: string $string |
openLDAP() X-Ref |
Opens a connection to the configured LDAP server and sets the wanted option on the connection author: Andreas Gohr <andi@splitbrain.org> |
ldapSearch($link_identifier,$base_dn,$filter,$scope = 'sub',$attributes = null,$attrsonly = 0,$sizelimit = 0) X-Ref |
Wraps around ldap_search, ldap_list or ldap_read depending on $scope author: Andreas Gohr <andi@splitbrain.org> return: resource param: resource $link_identifier param: string $base_dn param: string $filter param: string $scope can be 'base', 'one' or 'sub' param: null|array $attributes param: int $attrsonly param: int $sizelimit |
debug($message, $err, $line, $file) X-Ref |
Wrapper around msg() but outputs only when debug is enabled return: void param: string $message param: int $err param: int $line param: string $file |