Lines Matching refs:ctrl

239 static void _php_ldap_control_to_array(LDAP *ld, LDAPControl* ctrl, zval* array, int request)  in _php_ldap_control_to_array()  argument
243 add_assoc_string(array, "oid", ctrl->ldctl_oid); in _php_ldap_control_to_array()
246 add_assoc_bool(array, "iscritical", (ctrl->ldctl_iscritical != 0)); in _php_ldap_control_to_array()
250 if (strcmp(ctrl->ldctl_oid, LDAP_CONTROL_PASSWORDPOLICYRESPONSE) == 0) { in _php_ldap_control_to_array()
255 rc = ldap_parse_passwordpolicy_control(ld, ctrl, &expire, &grace, &pperr); in _php_ldap_control_to_array()
268 } else if (strcmp(ctrl->ldctl_oid, LDAP_CONTROL_PAGEDRESULTS) == 0) { in _php_ldap_control_to_array()
273 if (ctrl->ldctl_value.bv_len) { in _php_ldap_control_to_array()
275 rc = ldap_parse_pageresponse_control(ld, ctrl, &lestimated, &lcookie); in _php_ldap_control_to_array()
293 …} else if ((strcmp(ctrl->ldctl_oid, LDAP_CONTROL_PRE_READ) == 0) || (strcmp(ctrl->ldctl_oid, LDAP_… in _php_ldap_control_to_array()
297 ber = ber_init(&ctrl->ldctl_value); in _php_ldap_control_to_array()
332 } else if (strcmp(ctrl->ldctl_oid, LDAP_CONTROL_SORTRESPONSE) == 0) { in _php_ldap_control_to_array()
337 if (ctrl->ldctl_value.bv_len) { in _php_ldap_control_to_array()
338 rc = ldap_parse_sortresponse_control(ld, ctrl, &errcode, &attribute); in _php_ldap_control_to_array()
353 } else if (strcmp(ctrl->ldctl_oid, LDAP_CONTROL_VLVRESPONSE) == 0) { in _php_ldap_control_to_array()
358 if (ctrl->ldctl_value.bv_len) { in _php_ldap_control_to_array()
359 rc = ldap_parse_vlvresponse_control(ld, ctrl, &target, &count, &context, &errcode); in _php_ldap_control_to_array()
377 if (ctrl->ldctl_value.bv_len) { in _php_ldap_control_to_array()
378 add_assoc_stringl(array, "value", ctrl->ldctl_value.bv_val, ctrl->ldctl_value.bv_len); in _php_ldap_control_to_array()
385 static int _php_ldap_control_from_array(LDAP *ld, LDAPControl** ctrl, zval* array) in _php_ldap_control_from_array() argument
677 rc = ldap_control_create(ZSTR_VAL(control_oid), control_iscritical, &control_value, 1, ctrl); in _php_ldap_control_from_array()
723 *ctrl = NULL; in _php_ldap_control_from_array()
4024 LDAPControl *ctrl, **lserverctrls = NULL, *requestctrls[2] = { NULL, NULL }; in PHP_FUNCTION() local
4040 if (ldap_create_passwordpolicy_control(ld->link, &ctrl) == LDAP_SUCCESS) { in PHP_FUNCTION()
4041 requestctrls[0] = ctrl; in PHP_FUNCTION()