SSO Auth Error

Issue #1178 resolved
Игорь Жуковец created an issue

Hi,

We have a clean installation. And we try to coop mailpiler with AD.

It’s look like the very last changes in auth.php cause to error while using SSO.

Apache debug log shows error like:

got response: AF DOMAIN\\username
authenticated DOMAIN\\username
...
PHP Fatal error:  Uncaught ArgumentCountError: Too few arguments to function ModelUserAuth::get_email_array_from_ldap_attr(), 1 passed in /var/piler/www/model/user/auth.php on line 538 and exactly 2 expected in /var/piler/www/model/user/auth.php:295\nStack trace:\n#0 /var/piler/www/model/user/auth.php(538): ModelUserAuth->get_email_array_from_ldap_attr()\n#1 /var/piler/www/controller/login/sso.php(27): ModelUserAuth->check_ntlm_auth()\n#2 /var/piler/www/system/front.php(36): ControllerLoginSSO->index()\n#3 /var/piler/www/system/front.php(14): Front->execute()\n#4 /var/piler/www/sso.php(40): Front->dispatch()\n#5 {main}\n  thrown in /var/piler/www/model/user/auth.php on line 295

Compare existing installation (1.3.10 build 998) with working SSO installed in other site and current new one (1.3.11 build 1001) - there is difference at least in auth.php in function get_email_array_from_ldap_attr:

//1.3.10
public function get_email_array_from_ldap_attr($e = array())

//1.3.11
public function get_email_array_from_ldap_attr($e = array(), $group_object_class)

There are other changes in at least auth.php (and in this function body too), but I have no idea if it affects functioning.

Looks like changes in auth.php not reflected in other places.

Piler -v 1.3.11 build 1001

Comments (2)

  1. Игорь Жуковец reporter

    Looks like it was already fixed.

    Replace current auth.php with new one from repo and it works perfectly.

  2. Log in to comment