File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -361,9 +361,8 @@ func (m *manager) GetUserGroups(ctx context.Context, uid *userpb.UserId) ([]stri
361361 return groups , nil
362362 }
363363
364- // TODO (gdelmont): support pagination! we may have problems with users having more than 1000 groups
365- url := fmt .Sprintf ("%s/api/v1.0/Identity/%s/groups/recursive?field=displayName" , m .conf .APIBaseURL , uid .OpaqueId )
366-
364+ // no pagination here because a user can be member of 1010 groups at most (Microsoft AD hardcoded limitation)
365+ url := fmt .Sprintf ("%s/api/v1.0/Identity/%s/groups/recursive?filter=blocked%%3Afalse&filter=disabled%%3Afalse&field=displayName" , m .conf .APIBaseURL , uid .OpaqueId )
367366 var r GroupsResponse
368367 if err := m .apiTokenManager .SendAPIGetRequest (ctx , url , false , & r ); err != nil {
369368 return nil , err
You can’t perform that action at this time.
0 commit comments