Closed ChristineWk closed 3 years ago
The LDAP package has not significantly changed since 2018 https://github.com/joomla-framework/ldap/commits/2.0-dev
We are not using the Framework LDAP package but symfony/ldap in 4.0
I cannot replicate this.
I can login with any LDAP user.
Running LDAP in docker (Documentation)
docker run --rm -p 10389:10389 -p 10636:10636 rroemhild/test-openldap
and then with my configuration
Login with Username: amy Password: amy
After logging back in to the backend,
Promoted amy to a super admin, then attempted to login to admin - and that worked too.
Translation
After I made it from 3.10 to Joomla 4.0 yesterday, everything went almost smoothly. However, I was shown the following when I wanted to go to the posts, categories and main entries: the following error message: Class 'JPlatform' not found
After that, I gradually deactivated plugins and components, but the error message persisted.
At some point I logged out and when I wanted to log in again, this error message came up: An error occurred. 0 The option "host" with value null is expected to be of type "string", but is of type "null".
So maybe an upgrade issue, but certainly not an issue out of the box.
As you cannot login you will need to access the db directly and check the settings for the LDAP. (Or enable the Joomla Authentication plugin and login with a known good joomla user/pass)
You need to check the settings in the db #__extensions table, look for plg_authentication_ldap
in the name and look at the params, for reference mine are:
{"host":"host.docker.internal","port":10389,"use_ldapV3":1,"negotiate_tls":0,"ignore_reqcert_tls":1,"no_referrals":1,"auth_method":"search","base_dn":"ou=people,dc=planetexpress,dc=com","search_string":"uid=[search]","users_dn":"cn=[username],dc=planetexpress,dc=com","username":"admin","password":"GoodNewsEveryone","ldap_fullname":"displayName","ldap_email":"mail","ldap_uid":"uid","ldap_debug":1}
made pretty for viewing:
{
"host": "host.docker.internal",
"port": 10389,
"use_ldapV3": 1,
"negotiate_tls": 0,
"ignore_reqcert_tls": 1,
"no_referrals": 1,
"auth_method": "search",
"base_dn": "ou=people,dc=planetexpress,dc=com",
"search_string": "uid=[search]",
"users_dn": "cn=[username],dc=planetexpress,dc=com",
"username": "admin",
"password": "GoodNewsEveryone",
"ldap_fullname": "displayName",
"ldap_email": "mail",
"ldap_uid": "uid",
"ldap_debug": 1
}
Thanks for checking @PhilETaylor will report your findings back to him when I'm back at my desk later today. So it might be solved by going to the settings and check and save the configurations again.
as we have no details other than it was an upgrade, I can only assume.
What I have proved is that the feature - when correctly configured (to a known LDAP server) correctly works as advertised.
..... and that @wilsonge probably did not need to tag the framework ldap package 2 days ago :)
We decided removing the package at the last minute would probably annoy someone in an extension somewhere even if it wasn't used by core. It was a discussion in the last 24 hours.
Hallo @PhilETaylor
do you mean the file? Sorry, I'm only a user and don't really know about databases etc..
<?xml version="1.0" encoding="utf-8"?>
meinst du die Datei? Sorry, ich bin nur Anwender und kenne mich nicht wirklich mit Datenbanken etc. aus.
Please run the following on the database (phpmyadmin) to get what @PhilETaylor requested (please replace #__ with your database prefix you can find in the configuration.php.
select params from `#__extensions` where `element` = 'ldap' and `type` = 'plugin';
i entered it exactly like this, but can't find it.
Where did you enter it? You have to replace #__ with your database prefix ;-)
yes I have also done so:
select params from *****_extensions
where element
= 'ldap' and type
= 'plugin';
and where did you entered that command? It should be in phpmyadmin on the database that your joomla 3.10 site runs
I entered the command in the phpmyadmin on the database. And it is the Joomla 4.0
Hmm please send me a database dump to tobias.zulauf@community.joomla.org and I can take a look into it to extract the data Phil is looking for,
Thanks for your help! This is all a bit much for me right now. I can't really follow the requirements or I have to read up first. I'll give up for now.
Regards, Linus.
I can replicate this only when LDAP Plugin is enabled AND if I dont provide a value for the LDAP server address. Therefore I believe this is the root issue - maybe Joomla should validate it, maybe it could be put down to user error?
https://github.com/joomla/joomla-cms/pull/35233 will prevent people locking themselves out of Joomla and will allow other authentication methods to run even if LDAP is unconfigured.
Thnaks @PhilETaylor
Steps to reproduce the issue
The following was reported by a Forum de user: https://forum.joomla.de/thread/14122-fehlermeldung-der-admin-anmeldung/?postID=91310#post91310
Expected result
Maybe possibly PR for J 4.0.1
Actual result
After logging back in to the backend, the following message came up:
Call Stack:
Call stack
Function Location
1 () JROOT/libraries/vendor/symfony/options-resolver/OptionsResolver.php:1059 2 Symfony\Component\OptionsResolver\OptionsResolver->offsetGet() JROOT/libraries/vendor/symfony/options-resolver/OptionsResolver.php:924 3 Symfony\Component\OptionsResolver\OptionsResolver->resolve() JROOT/libraries/vendor/symfony/ldap/Adapter/AbstractConnection.php:30 4 Symfony\Component\Ldap\Adapter\AbstractConnection->__construct() JROOT/libraries/vendor/symfony/ldap/Adapter/ExtLdap/Adapter.php:41 5 Symfony\Component\Ldap\Adapter\ExtLdap\Adapter->getConnection() JROOT/libraries/vendor/symfony/ldap/Ldap.php:40 6 Symfony\Component\Ldap\Ldap->bind() JROOT/plugins/authentication/ldap/ldap.php:139 7 PlgAuthenticationLdap->onUserAuthenticate() JROOT/libraries/src/Authentication/Authentication.php:177 8 Joomla\CMS\Authentication\Authentication->authenticate() JROOT/libraries/src/Application/CMSApplication.php:819 9 Joomla\CMS\Application\CMSApplication->login() JROOT/libraries/src/Application/AdministratorApplication.php:384 10 Joomla\CMS\Application\AdministratorApplication->login() JROOT/administrator/components/com_login/src/Controller/DisplayController.php:80 11 Joomla\Component\Login\Administrator\Controller\DisplayController->login() JROOT/libraries/src/MVC/Controller/BaseController.php:730 12 Joomla\CMS\MVC\Controller\BaseController->execute() JROOT/libraries/src/Dispatcher/ComponentDispatcher.php:146 13 Joomla\CMS\Dispatcher\ComponentDispatcher->dispatch() JROOT/administrator/components/com_login/src/Dispatcher/Dispatcher.php:43 14 Joomla\Component\Login\Administrator\Dispatcher\Dispatcher->dispatch() JROOT/libraries/src/Component/ComponentHelper.php:389 15 Joomla\CMS\Component\ComponentHelper::renderComponent() JROOT/libraries/src/Application/AdministratorApplication.php:143 16 Joomla\CMS\Application\AdministratorApplication->dispatch() JROOT/libraries/src/Application/AdministratorApplication.php:186 17 Joomla\CMS\Application\AdministratorApplication->doExecute() JROOT/libraries/src/Application/CMSApplication.php:278 18 Joomla\CMS\Application\CMSApplication->execute() JROOT/administrator/includes/app.php:63 19 require_once() JROOT/administrator/index.php:32
System information (as much as possible)
Joomla! 3.10 to Joomla! 4.0.0
Additional comments
More information from the TE will be submitted tomorrow. Information about Plugin settings are pending.
Any additional relevant information from: @zero24