mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
e47863e840
There is at least one LDAP server (Sun Directory Server) that doesn't support Paged Results extension, even if it supports LDAP version 3. So checking just for LDAP version is not enough. If possible, we check the supportedControl attribute of the LDAP rootDSE and see if the paged results control is available. This needs an LDAP connection, which might not be possible to establish before we configure some essential LDAP settings (server, bind user, password, etc.). Thus we try to establish the connection and check the supportedControl attribute. But if we fail, we perform only basic checks that are less accurate and err on the side of cautiousness.