Skip to content

occ ldap_user issue #9394

Closed
Closed

Description

@tanguy-opendsi

I'm using a script with the occ user ldap command

here your have all commands :

sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapAgentName LDAP
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapAgentPassword PASSWORD
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapPort 389
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapBase DC=SENSIBLE,DC=local
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapHost Srv-ad-006.SENSIBLE.local
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapConfigurationActive 1
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapExperiencedAdmin 1
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapGroupFilter (&(|(objectclass=group))(|(cn=TESTXXX-NC*)))
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapUserFilter (&(objectclass=person)(memberof=CN=TESTXXX-FILESHARE,OU=TESTXXX,OU=EMEA,OU=SENSIBLE,DC=SENSIBLE,DC=local))
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapUserFilterGroups TESTXXX-FILESHARE
sudo -u www-data php /var/www/nextcloud/occ ldap:set-config s01 ldapLoginFilter (&(&(objectclass=person)(memberof=CN=TESTXXX-FILESHARE,OU=TESTXXX,OU=EMEA,OU=SENSIBLE,DC=SENSIBLE,DC=local))(samaccountname=%uid))

The probleme is :
I can't log with ldap user, i have to sing in nextcloud with admin user, And i need to test 2 times the user ldap filter.
The first time nextcloud say 0 user found
The second time nextcloud say 2 users found.

I have to deploy nextcloud in script with LDAP parameters.
My filters works but i have to use gui to init the ldap

Can you help me ?

Server configuration

Operating system: debian9
Web server: Apache

Database: MariaDB

PHP version: 7.1

Nextcloud version: 13.0.2

Best regards

Activity

  1. MorrisJobke commented on May 7, 2018

    @MorrisJobke
    Member

    cc @nextcloud/ldap

  2. tanguy-opendsi commented on May 7, 2018

    @tanguy-opendsi
    Author

    Look like to be this problem ? : #8536

  3. blizzz commented on May 7, 2018

    @blizzz
    Member

    You are rather missing something critical (displayname i guess) when you configure it by script. Since it works when you use the wizard, which triggers auto-detection of some values. You can compare the ouput of occ ldap:show-config before and after using the config wizard.

    I am using scripted config (just via API but there's no real difference) successfully here: https://github.com/nextcloud/univention-app/blob/master/inst#L114-L166

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions