nextcloud / nextcloud/ldap_contacts_backend
Can't configure LDAP backend
Open
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 9
- Forks
- 7
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 25
Description
I can't configure any LDAP backend on Nextcloud 20.0.2:
sudo -u www-data /usr/bin/php occ ldap_contacts:add --interactive $TEST
Address book display name: TEST
An unhandled exception has been thrown:
TypeError: Argument 3 passed to OCA\LDAPContactsBackend\Service\ConnectionImporter::extractTlsMode() must be of the type string, int given, called in /var/www/html/apps/ldap_contacts_backend/lib/Service/ConnectionImporter.php on line 71 and defined in /var/www/html/apps/ldap_contacts_backend/lib/Service/ConnectionImporter.php:84
Stack trace:
#0 /var/www/html/apps/ldap_contacts_backend/lib/Service/ConnectionImporter.php(71): OCA\LDAPContactsBackend\Service\ConnectionImporter->extractTlsMode()
#1 /var/www/html/apps/ldap_contacts_backend/lib/Command/Add.php(322): OCA\LDAPContactsBackend\Service\ConnectionImporter->getAvailableConnections()
#2 /var/www/html/apps/ldap_contacts_backend/lib/Command/Add.php(158): OCA\LDAPContactsBackend\Command\Add->askImport()
#3 /var/www/html/3rdparty/symfony/console/Command/Command.php(240): OCA\LDAPContactsBackend\Command\Add->interact()
#4 /var/www/html/core/Command/Base.php(169): Symfony\Component\Console\Command\Command->run()
#5 /var/www/html/3rdparty/symfony/console/Application.php(1000): OC\Core\Command\Base->run()
#6 /var/www/html/3rdparty/symfony/console/Application.php(271): Symfony\Component\Console\Application->doRunCommand()
#7 /var/www/html/3rdparty/symfony/console/Application.php(147): Symfony\Component\Console\Application->doRun()
#8 /var/www/html/lib/private/Console/Application.php(215): Symfony\Component\Console\Application->run()
#9 /var/www/html/console.php(100): OC\Console\Application->run()
#10 /var/www/html/occ(11): require_once('/var/www/html/c...')
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with lib/Service/ConnectionImporter.php, especially extractTlsMode() and its caller around line 71, then reproduce the failure with occ ldap_contacts:add --interactive. Done means the command can configure an LDAP backend without the reported TypeError and the TLS mode is handled correctly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100