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 GitLab shared exclusion flag #3572

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

rosecodym
Copy link
Collaborator

@rosecodym rosecodym commented Nov 7, 2024

Description:

We've been seeing some suspicious behavior from the GitLab API when we're scanning a very large organization that has lots of group sharing. Since reproducing the behavior in a test environment isn't really tractable, this PR adds an optional configuration flag that can be used to investigate the phenomenon in the actual environment we're seeing it in.

Checklist:

  • Tests passing (make test-community)?
  • Lint passing (make lint this requires golangci-lint)?

@rosecodym rosecodym requested review from a team as code owners November 7, 2024 22:09
@@ -577,6 +582,7 @@ func (s *Source) getAllProjectRepos(
ListOptions: listOpts,
OrderBy: gitlab.Ptr(orderBy),
IncludeSubGroups: gitlab.Ptr(true),
WithShared: gitlab.Ptr(s.enumerateSharedProjects),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The docs indicate with_shared defaults to true. Is this config option here to disable with_shared for debug testing?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes exactly

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

Successfully merging this pull request may close these issues.

3 participants