Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add missing functions to LdapUserViewProvider #137

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tbenk
Copy link

@tbenk tbenk commented Aug 29, 2017

LDAP does not work out of the box for me, i had to add the following three dummy functions to get it working:

  • getGroupsOfSubgroup($objGroup)
  • getSubgroupsOfGroup($objGroup)
  • isSubgroupInGroup($objSubgroup, $objGroup)

Error message:

[Tue Aug 29 05:32:21.674119 2017] [:error] [pid 25831] [client 77.20.128.83:7317] PHP Fatal error: Class svnadmin\providers\ldap\LdapUserViewProvider contains 3 abstract methods and must therefore be declared abstract or implement the remaining methods (svnadmin\core\interfaces\IGroupViewProvider::getGroupsOfSubgroup, svnadmin\core\interfaces\IGroupViewProvider::getSubgroupsOfGroup, svnadmin\core\interfaces\IGroupViewProvider::isSubgroupInGroup) in /srv/www/htdocs/svnadmin/classes/providers/ldap/LdapUserViewProvider.class.php on line 22

- getGroupsOfSubgroup($objGroup)
- getSubgroupsOfGroup($objGroup)
- isSubgroupInGroup($objSubgroup, $objGroup)
@Rincewind34
Copy link

Hey there,
in case anybody else does have issues with ldap: this implementation is not correct and DOES NOT work. LDAP itself doesn't support nested groups (or inheritance) so those methods can be implemented correctly fairly easily:

  • return an empty array in getGroupsOfSubgroup and getSubgroupsOfGroup (return array();)
  • return false in isSubgroupInGroup

Hope this is cutting an hour of searching from anyone who tries it next ;)

userid0x0 added a commit to userid0x0/iF.SVNAdmin that referenced this pull request Oct 2, 2024
apply patch initially discussed in mfreiholz#137
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants