CVE-2021-22865 Improper access control in GitHub Enterprise Server leading to unauthorized read access to private repository metadata
Attackers can read private repository metadata via REST API using GitHub App tokens without proper permissions, affecting GitHub Enterprise Server users.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- None listed
What is CVE-2021-22865?
CVE-2021-22865 is a medium-severity missing authorization vulnerability in Github Enterprise Server, published on 2 Apr 2021. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
An improper access control vulnerability was identified in GitHub Enterprise Server that allowed access tokens generated from a GitHub App's web authentication flow to read private repository metadata via the REST API without having been granted the appropriate permissions. To exploit this vulnerability, an attacker would need to create a GitHub App on the instance and have a user authorize the application through the web authentication flow. The private repository metadata returned would be limited to repositories owned by the user the token identifies. This vulnerability affected all versions of GitHub Enterprise Server prior to 3.0.4 and was fixed in versions 3.0.4, 2.22.10, 2.21.18. This vulnerability was reported via the GitHub Bug Bounty program.
Weakness: CWE-285
Which versions are affected by CVE-2021-22865?
It affects 1 product.
Products include Github Enterprise Server.
How do I fix CVE-2021-22865?
No fix has been published for CVE-2021-22865 yet. Limit exposure of the affected software until one is available.
Upgrade, and check permissions on every request on the server, not only in the interface. More about Missing authorization.
Is CVE-2021-22865 being exploited?
There is no known exploitation of CVE-2021-22865 in the wild and no public exploit code.
Other vulnerabilities in Github Enterprise Server
- CVE-2024-4985 Auth bypass in Enterprise Server
- CVE-2022-23739 Missing authorization in GitHub Enterprise Server
- CVE-2022-46255 Improper Limitation of a Pathname to a Restricted Directory in GitHub Enterprise Server leading to RCE
- CVE-2021-22869 Improper access control in GitHub Enterprise Server allows self-hosted runners to execute outside their control group
- CVE-2024-9487 Auth bypass in Enterprise Server
Sources
Also known as GHSA-735f-v862-xcr3.