Skip to content
This repository was archived by the owner on Sep 30, 2024. It is now read-only.
This repository was archived by the owner on Sep 30, 2024. It is now read-only.

Sourcegraph Doesn't Respect Repo Visibility Rules For GitHub Enterprise  #56648

@alexAtSourcegraph

Description

@alexAtSourcegraph
  • Sourcegraph version: 5.1.8
  • Platform information: All Sourcegraph Platforms

Steps to reproduce:

  1. Generate a personal access token for a user in GitHub Enterprise Server that is an Enterprise Member as defined here
  2. Use the personal access token to create a code host connection in Sourcegraph.
  3. Choose the "affiliated" repositoryQuery to specify what repositories the user has access to.

Expected behavior:

The use of the personal access token of an Enterprise Member as well as using the repositoryQuery key and affiliated value would pull in all of the public repositories in a GitHub Enterprise Server instance (regardless if the user belonged to an organization) as well as all of the internal repositories in addition to the private repositories it should have access to. This behavior is based on the repo visibility rules expressed by GitHub Enterprise here.

Actual behavior:

Sourcegraph currently only pulls in the public repos on the instance that do not belong to an organization, public repos that belong to the organizations that the user is in and private repositories that the user has been given explicit access to.

/cc @sourcegraph/source

Metadata

Metadata

Assignees

Labels

EE/paper cutscustomer issues that will be worked on as part of EE rotationbugAn error, flaw or fault that produces an incorrect or unexpected result, or behavior.team/sourceTickets under the purview of Source - the one Source to graph it all

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions