fix(api): stop leaking private repo metadata after access revocation#38321
Open
bircni wants to merge 1 commit into
Open
fix(api): stop leaking private repo metadata after access revocation#38321bircni wants to merge 1 commit into
bircni wants to merge 1 commit into
Conversation
The starred (`/user/starred`) and subscriptions (`/user/subscriptions`) endpoints returned private repositories a user had starred/watched even after their access to those repositories was revoked, exposing repo name, description and visibility. Gate private repositories in the starred/watched queries on the actor's current access via AccessibleRepositoryCondition, so revoked users no longer receive their metadata.
lunny
approved these changes
Jul 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
/user/starredand/user/subscriptionsendpoints returned private repositories a user had starred/watched even after their access to those repositories was revoked, still exposing the repository name, description and visibility (including later metadata changes).Private repositories in the starred/watched queries are now gated on the actor's current access via
AccessibleRepositoryCondition, so users who no longer have access no longer receive the metadata. Public repositories and public-only tokens are unaffected.