Closed davewkzn closed 10 years ago
I have the same problem and I haven't found anything googling around... the problem appears after upgrade 8.0.1 to 8.0.2
Thanks for your reply. I am glad to hear that I am not alone :)
I've changed this:
public function searchDirectory($domain, $limit = 10, $offset = 0, $type = 'accounts', $sort = null, $query = null)
{
if ($type == 'accounts') {
$ldapQuery = "&(";
if ($query !== null) {
$ldapQuery .= "(name=$query*)";
}
$ldapQuery .= '(!(zimbraIsSystemResource=TRUE))';
$ldapQuery .= '(!(zimbraIsAdminAccount=TRUE))';
$ldapQuery .= ')';
} else {
$ldapQuery = '';
}
....
with:
public function searchDirectory($domain, $limit = 10, $offset = 0, $type = 'accounts', $sort = null, $query = null)
{
$ldapQuery = '';
....
and is working for GetAllAccounts(), before confirm the validity of the solution is necessary some additional tests
Thank you for your input!
Upon further inspection, it would appear that the following at line 50 in Admin.php: $ldapQuery = "&(";
Is causing the ampersand symbol to appear on the wrong side of the parentheses in the search query. From what I can see it should rather be: $ldapQuery = "(&";
Tested and working on my system so far.
really good!
thanks, is working!
Merged, thanks.
Hi,
Please may I ask for your assistance with the following?
When attempting to use the example which lists all accounts via "$zimbra->getAccounts", I receiving the following error: PHP Fatal error: Uncaught exception 'Zimbra\ZCS\Exception' with message 'An unexpected error has occurred (ldap.INVALID_SEARCH_FILTER)' in /var....../zcs-php/src/Zimbra/ZCS/SoapClient.php:103
According to our Zimbra server's log I see the following: errorMessage='Unexpected opening parenthesis found at position 72 of the filter string.'
Have I done something wrong? Your assistance would be greatly appreciated. Zimbra version: zimbra-8.0.2 Many thanks.