镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

[ldap] Add ldap domain socket (ldapi:///) support #24497

Closed

Description

@zenlord

See ##7737 for a description of the issue. That bug was closed in May 2019, but in my 20.0.2 installation of nextcloud, the problem is still present.

I have identified the files that require changes in the user_ldap app:

  • lib/Connection.php (backend)
  • lib/LDAP.php (backend)
  • lib/Wizard.php (frontend)

Making the changes to the backend files as done previously by @nick-dumas in his commit nick-dumas@72b8054 has proven to work for me, so I intend to make the required changes and then send in a PR.

Activity

  1. added
    0. Needs triagePending check for reproducibility or if it fits our roadmap
    on Dec 2, 2020
  2. nick-dumas commented on Dec 2, 2020

    @nick-dumas

    Thanks @zenlord.
    I ran a patched version for a while and it worked for me, so feel free to use my changes.

  3. zenlord commented on Dec 3, 2020

    @zenlord
    ContributorAuthor

    I'm struggling with the frontend patch. I have made the required changes to get the Wizard to respond 'Configuration OK', but the tab headings for 'Users', 'Login Attributes' etc. stay greyed out and do not become available.

    @nextcloud/ldap @blizzz any hints where the checks to enable these tabs can be found so I can send in a pull request?

  4. blizzz commented on Dec 3, 2020

    @blizzz
    Member

    @zenlord this probably depends on ajax/testConfiguration.php which eventually triggers the doCriticalValidation() in lib/Connection.php. But the changes on the linked commit should deal with it. Maybe you double check that?

  5. zenlord commented on Dec 3, 2020

    @zenlord
    ContributorAuthor

    @blizzz At first I thought my configuration was at fault, but even after resetting to default I still was unable to switch tabs in the LDAP settings section.

    The ajax/ folder doesn't contain anything relevant, but the js/wizard/ folder does (83 hits for 'port' spread over 20 files :( ), and it seems that quite some checks are triggering an auto-detection of the port number. I'll do some further digging, but JS is not my strongsuit.

  6. zenlord commented on Dec 3, 2020

    @zenlord
    ContributorAuthor

    I made some progress by adding an additional condition in two functions inside js/wizard/view.js:

    basicStatusCheck()

    if((host && port  && base) && ((!agent && !pwd) || (agent && pwd))) {
      view.enableTabs();
    } else if((host && base && host.indexOf('ldapi://') > -1 ) && ((!agent && !pwd) || (agent && pwd))) {
      view.enableTabs();
    } else {
      view.disableTabs();
    }
    

    (and similar in functionalityCheck()

    But the behaviour is erratic: e.g. the check for a username returns 'user found', but the count for users returns 0 ...

  7. zenlord commented on Dec 3, 2020

    @zenlord
    ContributorAuthor

    Errors were indeed in my configuration (and in me misunderstanding the 'edit Query filter' functionality - one has to click the underlined text for the filter in the textfield to become active...).
    I'll send in a pull request over the weekend.

  8. zenlord commented on Nov 20, 2021

    @zenlord
    ContributorAuthor

    Not sure what I have to do. I have filed a pull request that solves this issue almost one year ago, and I am able to apply the patches manually to versions 20, 21 and now also 22.2.3. The PR just sits there.
    #24574
    Am I doing something wrong?

  9. xandris commented on Jun 12, 2023

    @xandris

    @zenlord #24574 is merged now, is this issue resolved?

  10. zenlord commented on Jun 25, 2023

    @zenlord
    ContributorAuthor

    Yes, I just upgraded this instance to v26.0.3 and I no longer have to patch the source files myself.

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