Skip to main content

go-git CVE-2026-71556

| EUVDEUVD-2026-54526 HIGH
Improper Link Resolution Before File Access (CWE-59)
2026-08-07 GitHub_M GHSA-hc8v-wwc9-vgxm
7.1
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Attacker crafts git repo with planted symlinks
  2. Delivery
    Victim clones repository using vulnerable go-git
  3. Exploit
    Victim application invokes worktree operation (checkout/add/status)
  4. Execution
    go-git passes path string validation but follows symlink at OS level
  5. Persist
    Write operation escapes worktree boundary
  6. Impact
    Target files (e.g., .git/config) overwritten outside intended directory

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Symlink resolution safety
Exploitation Conditions

Exploitation requires all of the following: the victim application must use go-git with a filesystem-backed worktree (not storage/memory or go-billy/memfs); the attacker must be able to supply a repository the victim will clone (either a publicly hosted malicious repo or a compromised internal repo); and the victim application must invoke at least one worktree operation (checkout, add, or status) after cloning - a bare clone alone is insufficient. Exploitation is limited by the UI:R requirement: fully automated exploitation without any victim-side worktree operation is not possible. The attack does not require any authentication on the victim side (PR:N) nor elevated attacker privileges. The scope is unchanged (S:U): writes exit the worktree path but remain within the user's local filesystem authority, so no cross-privilege-boundary escalation is inherent to the flaw itself.

Impact

The CVSS 3.1 score of 7.1 (High) is driven by AV:N/AC:L/PR:N/UI:R with I:H - indicating that the attack is network-delivered, low-complexity for the attacker, requires no attacker privileges, but does require a victim to interact with (clone and operate on) a malicious repository. The I:H rating reflects that overwriting .git/config or arbitrary files outside the worktree constitutes a complete integrity violation for the affected paths. The C:N assignment is notable: the original CVE description states the library may 'read from or write to files outside the intended working directory,' implying a potential confidentiality impact via symlink-following reads that the NVD vector does not capture - this discrepancy should be verified with the vendor. No EPSS data was provided in the input; no KEV listing exists at time of analysis, indicating no confirmed widespread active exploitation. The practical risk depends heavily on deployment context: go-git consumers that clone arbitrary or untrusted user-supplied repositories (CI/CD runners, repository hosting platforms, code analysis pipelines) face the highest exposure, while deployments that only operate on internally-controlled repositories have substantially lower risk. The UI:R requirement and the need for the victim to subsequently invoke worktree operations beyond a bare clone reduce the automation potential compared to a fully unauthenticated, no-interaction flaw.

Exploit ScenarioDerived

An attacker creates a git repository containing a tracked file named 's' that is a symbolic link to the '.git' directory, then hosts the repository on a public or attacker-controlled Git server. A developer or automated CI/CD pipeline using a vulnerable go-git version clones the repository and invokes a worktree operation such as checkout or add. The go-git worktree code, after passing the string 's/config' through its path validator without rejection, follows the symlink at the filesystem level, causing a write to '.git/config' rather than a file named 's/config' inside the worktree - potentially overwriting repository configuration to redirect hooks, change remote URLs, or corrupt repository state.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
1 PoC candidate (unverified) Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Aug 07, 2026

Symlink traversal in go-git's worktree filesystem layer allows a maliciously crafted repository to cause write operations to escape the intended worktree boundary when cloned and operated upon. Affected are all filesystem-backed go-git deployments using v5 prior to 5.19.2 and v6 prior to 6.0.0-alpha.5. An attacker who controls a repository can plant symlinks such that a victim's go-git worktree operations (checkout, add, status) silently overwrite files outside the working directory - including critical Git metadata like .git/config - enabling repository poisoning or arbitrary local file corruption. No public exploit identified at time of analysis and no confirmed active exploitation (not listed in CISA KEV).

RemediationAI

Upgrade go-git v5 consumers to v5.19.2 and go-git v6 consumers to v6.0.0-alpha.5; both releases are confirmed fixed and available at https://github.com/go-git/go-git/releases/tag/v5.19.2 and https://github.com/go-git/go-git/releases/tag/v6.0.0-alpha.5 respectively. The underlying fix commits are https://github.com/go-git/go-git/commit/008a78f2dd86f52544ddff8b8e8ddeecdf3f7aab and https://github.com/go-git/go-git/commit/661d1c7f101d34e002a3cfcf8dbea5b7421d07ac. For deployments where upgrading is immediately infeasible, a targeted compensating control is to configure the Storer as storage/memory or use go-billy/memfs for the worktree filesystem, which eliminates the vulnerable real-filesystem code path entirely at the cost of in-memory operation (trade-off: no persistence, higher memory consumption for large repositories). If neither upgrade nor in-memory mode is viable, restricting the application to only clone repositories from fully trusted, internally-controlled sources eliminates the attacker's ability to plant malicious symlinks, though this requires application-layer enforcement rather than library-level protection.

Affected VersionsENISA

go-git 6.0.0-alpha.1, < 6.0.0-alpha.5
go-git < 5.19.2

Affected Packages

go github.com/go-git/go-git/v5 fix: 5.19.2
go github.com/go-git/go-git/v6 fix: 6.0.0-alpha.5
euvd go_git fix: 5.19.2
euvd go_git_6_0_0_alpha_1 fix: 6.0.0-alpha.5

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 4 packages in go, euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

CWE-59 (Improper Link Resolution Before File Access / Link Following) describes the root cause: a security wrapper validated path strings without enforcing that filesystem operations could not follow already-present symbolic links into restricted locations. The go-git worktreeFilesystem abstraction used by all filesystem-backed worktrees (CPE: cpe:2.3:a:go-git:go-git:*:*:*:*:*:*:*:*) rejected dangerous string patterns - .git references, parent-directory components (..), control characters - but did not prevent OS-level symlink resolution during file creation or opening. Two distinct attack shapes exist: (1) a symlink at a leading path component (e.g., 's' -> '.git'), causing writes to 's/config' to land in '.git/config'; (2) a symlink at the final path component (e.g., 's' -> '.git/config'), causing O_TRUNC opens to overwrite the symlink target. The fix introduced a clearBlockingSymlinks function that uses Lstat to detect and remove blocking symlinks before materializing entries, and added validNoLeadingSymlink checks to the worktreeFilesystem boundary for both read and write paths. Applications using storage/memory or go-billy/memfs are architecturally exempt because they never perform real filesystem operations.

Know when Go Git gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 7.1 HIGH
AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:L
vuln.today AI 7.6 HIGH

Adjusted C:N to C:L because the CVE description explicitly includes read-outside-worktree as an impact path alongside writes.

3.1 AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:H/A:L
4.0 AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:H/VA:L/SC:N/SI:N/SA:N
SUSE HIGH
Red Hat 7.1 HIGH

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
Low

Lifecycle Timeline

2
Patch available
Aug 07, 2026 - 17:17 EUVD
CVE Published
Aug 07, 2026 - 16:37 cve.org
HIGH 7.1

DescriptionCVE.org

go-git is an extensible git implementation library written in pure Go. Prior to 5.19.2 and 6.0.0-alpha.5, worktree operations (including checkout, status, and add) resolve symbolic links inside the working tree without confining resolution to the worktree boundary, so a maliciously crafted repository containing a symlink can cause go-git to read from or write to files outside the intended working directory when the repository is cloned and its worktree operations are used. Versions 5.19.2 and 6.0.0-alpha.5.

Latest POC

1 PoC candidate from github (unverified)

Sign in to open the public PoC links collected for this CVE.

Executive ViewAI

Why It Matters

A go-git vulnerability enables repository poisoning attacks that silently corrupt Git configuration and files, affecting organizations using the library for CI/CD automation and DevOps operations. Versions prior to 5.19.2 (v5 series) and 6.0.0-alpha.5 (v6 series) are vulnerable to file corruption when processing untrusted repositories, creating risks to build integrity and supply chain security. No public exploit identified at time of analysis; however, the high CVSS score and direct access to Git metadata warrant immediate remediation.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.3%
Top 79% exploitable
Prevalence
Medium
widely-used Go git library in developer tooling and CI/CD pipelines
Threat Intel
1
1 sources
Data Quality
8 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA MSRC Vendor GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC Yes
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact
High
Technical Impact
Partial

Priority Score

56
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +36
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

Vendor StatusVendor

SUSE

Severity: Important
Product Status
SUSE Linux Enterprise High Performance Computing 15 SP4 SUSE Linux Enterprise Module for Public Cloud 15 SP4 SUSE Linux Enterprise Server 15 SP4 SUSE Linux Enterprise Server for SAP Applications 15 SP4 SUSE Manager Proxy 4.3 SUSE Manager Retail Branch Server 4.3 SUSE Manager Server 4.3 Fixed
SUSE Linux Enterprise High Performance Computing 15 SP5 SUSE Linux Enterprise Module for Public Cloud 15 SP5 SUSE Linux Enterprise Server 15 SP5 SUSE Linux Enterprise Server for SAP Applications 15 SP5 Fixed
SUSE Linux Enterprise Desktop 15 SP7 Affected
SUSE Linux Enterprise Desktop 15 SP7 Not-Affected
SUSE Linux Enterprise High Performance Computing 12 Affected

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy