LDAP
In PHP 7.3, quite a few new improvements were made to
ext/ldap
, PHP’s extension for the Lightweight Directory
Access Protocol (LDAP).
We do not have an environment in which we could test these improvements and therefore cannot provide examples for how they are used. Instead, we can only list the improvements here:
The functions ldap_add_ext()
,
ldap_bind_ext()
, ldap_delete_ext()
,
ldap_mod_add_ext()
,
ldap_mod_replace_ext()
,
ldap_mod_del_ext()
, and ldap_rename_ext()
were added and provide access to the result object to be able to
parse it with ldap_parse_result()
. This gives more
detailed information than just “the operation failed” or “the
operation was successful”.
The ldap_exop_refresh()
was added for conveniently
performing an extended refresh operation.
Full support for LDAP Controls was added to the LDAP querying
functions as well as ldap_parse_result()
. The
serverctrls
parameter was added to the
ldap_add()
, ldap_mod_replace()
,
ldap_mod_add()
, ldap_mod_del()
,
ldap_rename()
, ldap_compare()
,
ldap_delete()
, ldap_modify_batch()
,
ldap_search()
, ldap_list()
, and
ldap_read()
functions for sending controls to the
server. The out
parameter was added to the
ldap_parse_result()
function for getting controls from
the server.
The LDAP_OPT_SERVER_CONTROLS
and
LDAP_OPT_CLIENT_CONTROLS
constants are now handled
correctly by the ldap_get_option()
and
ldap_set_option()
functions.