summaryrefslogtreecommitdiffstats
path: root/build/integration/ldap_features/ldap-openldap.feature
diff options
context:
space:
mode:
Diffstat (limited to 'build/integration/ldap_features/ldap-openldap.feature')
-rw-r--r--build/integration/ldap_features/ldap-openldap.feature58
1 files changed, 58 insertions, 0 deletions
diff --git a/build/integration/ldap_features/ldap-openldap.feature b/build/integration/ldap_features/ldap-openldap.feature
index 4b0b02c5b4f..2e1f637a50a 100644
--- a/build/integration/ldap_features/ldap-openldap.feature
+++ b/build/integration/ldap_features/ldap-openldap.feature
@@ -102,3 +102,61 @@ Feature: LDAP
| ldapHost | foo.bar |
| ldapPort | 2456 |
Then Expect ServerException on failed web login as "alice"
+
+ Scenario: Test LDAP group membership with intermediate groups not matching filter
+ Given modify LDAP configuration
+ | ldapBaseGroups | ou=OtherGroups,dc=nextcloud,dc=ci |
+ | ldapGroupFilter | (&(cn=Gardeners)(objectclass=groupOfNames)) |
+ | ldapNestedGroups | 1 |
+ | useMemberOfToDetectMembership | 1 |
+ | ldapUserFilter | (&(objectclass=inetorgperson)(!(uid=alice))) |
+ And As an "admin"
+ # for population
+ And sending "GET" to "/cloud/groups"
+ And sending "GET" to "/cloud/groups/Gardeners/users"
+ Then the OCS status code should be "200"
+ And the "users" result should match
+ | alice | 0 |
+ | clara | 1 |
+ | elisa | 1 |
+ | gustaf | 1 |
+ | jesper | 1 |
+
+ Scenario: Test LDAP group membership with intermediate groups not matching filter and without memberof
+ Given modify LDAP configuration
+ | ldapBaseGroups | ou=OtherGroups,dc=nextcloud,dc=ci |
+ | ldapGroupFilter | (&(cn=Gardeners)(objectclass=groupOfNames)) |
+ | ldapNestedGroups | 1 |
+ | useMemberOfToDetectMembership | 0 |
+ | ldapUserFilter | (&(objectclass=inetorgperson)(!(uid=alice))) |
+ And As an "admin"
+ # for population
+ And sending "GET" to "/cloud/groups"
+ And sending "GET" to "/cloud/groups/Gardeners/users"
+ Then the OCS status code should be "200"
+ And the "users" result should match
+ | alice | 0 |
+ | clara | 1 |
+ | elisa | 1 |
+ | gustaf | 1 |
+ | jesper | 1 |
+
+ Scenario: Test LDAP group membership with intermediate groups not matching filter, numeric group ids
+ Given modify LDAP configuration
+ | ldapBaseGroups | ou=NumericGroups,dc=nextcloud,dc=ci |
+ | ldapGroupFilter | (&(cn=2000)(objectclass=groupOfNames)) |
+ | ldapNestedGroups | 1 |
+ | useMemberOfToDetectMembership | 1 |
+ | ldapUserFilter | (&(objectclass=inetorgperson)(!(uid=alice))) |
+ And As an "admin"
+ # for population
+ And sending "GET" to "/cloud/groups"
+ And sending "GET" to "/cloud/groups/2000/users"
+ Then the OCS status code should be "200"
+ And the "users" result should match
+ | alice | 0 |
+ | clara | 1 |
+ | elisa | 1 |
+ | gustaf | 1 |
+ | jesper | 1 |
+