CVE-2026-76851: Server-Side Request Forgery vulnerability in GitHub Enterprise Server allowed remote code execution via network access from pre-receive hooks to internal services
A Server-Side Request Forgery (SSRF) vulnerability was identified in GitHub Enterprise Server that allowed remote code execution on the instance. Insufficient network isolation allowed malicious pre-receive hook code to impersonate an internal service and redirect trusted internal requests to a privileged service, leading to elevated code execution. Exploitation required pre-receive hook networking to be enabled and either site administrator privileges or write access to a repository containing a configured pre-receive hook. This vulnerability affected all versions of GitHub Enterprise Server prior to 3.22 and was fixed in versions 3.17.20, 3.18.14, 3.19.11, 3.20.7, and 3.21.5. This vulnerability was reported via the GitHub Bug Bounty program.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
GitHub Enterprise Serverto a version that resolves this vulnerability.Fixed in 3.17.20 - Upgrade
Upgrade
GitHub Enterprise Serverto a version that resolves this vulnerability.Fixed in 3.18.14 - Upgrade
Upgrade
GitHub Enterprise Serverto a version that resolves this vulnerability.Fixed in 3.19.11 - Upgrade
Upgrade
GitHub Enterprise Serverto a version that resolves this vulnerability.Fixed in 3.20.7 - Upgrade
Upgrade
GitHub Enterprise Serverto a version that resolves this vulnerability.Fixed in 3.21.5
Event History
Frequently Asked Questions
Who can exploit this vulnerability?
Exploitation requires pre-receive hook networking to be enabled. An attacker must also have either site administrator privileges or write access to a repository that has a pre-receive hook configured.
Are default GitHub Enterprise Server deployments affected?
The vulnerability requires pre-receive hook networking to be enabled, so deployments without that capability enabled do not meet the stated exploitation prerequisites. The issue affects all GitHub Enterprise Server versions before 3.22 when the required conditions are present.
Which versions contain a fix?
Fixes are available in GitHub Enterprise Server 3.17.20, 3.18.14, 3.19.11, 3.20.7, and 3.21.5. All versions prior to 3.22 are identified as affected.
What can be done if upgrading cannot happen immediately?
Disable pre-receive hook networking to remove a stated prerequisite for exploitation. Also restrict write access to repositories with configured pre-receive hooks and limit site administrator access.