CVE-2025-26625 Git LFS may write to arbitrary files via crafted symlinks

High 8.6 Published Updated

Git LFS allows arbitrary file writes via crafted symlinks during checkout or pull, enabling attackers to modify files outside the repository.

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
Available

What is CVE-2025-26625?

CVE-2025-26625 is a high-severity path traversal vulnerability in git-lfs, published on 17 Oct 2025. 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

Git LFS is a Git extension for versioning large files. In Git LFS versions 0.5.2 through 3.7.0, when populating a Git repository's working tree with the contents of Git LFS objects, certain Git LFS commands may write to files visible outside the current Git working tree if symbolic or hard links exist which collide with the paths of files tracked by Git LFS. The git lfs checkout and git lfs pull commands do not check for symbolic links before writing to files in the working tree, allowing an attacker to craft a repository containing symbolic or hard links that cause Git LFS to write to arbitrary file system locations accessible to the user running these commands. As well, when the git lfs checkout and git lfs pull commands are run in a bare repository, they could write to files visible outside the repository. The vulnerability is fixed in version 3.7.1. As a workaround, support for symlinks in Git may be disabled by setting the core.symlinks configuration option to false, after which further clones and fetches will not create symbolic links. However, any symbolic or hard links in existing repositories will still provide the opportunity for Git LFS to write to their targets.

Weakness: CWE-59

Which versions are affected by CVE-2025-26625?

5 open source packages ship an affected version, including github.com/git-lfs/git-lfs, git-lfs and github.com/git-lfs/git-lfs/v3.

PackageAffectedFixed in
github.com/git-lfs/git-lfs GoFrom 0.5.2None
github.com/git-lfs/git-lfs GoFrom 0.5.23.7.1
github.com/git-lfs/git-lfs GoFrom 0.5.23.7.1
git-lfs BitnamiFrom 0.5.23.7.1
github.com/git-lfs/git-lfs/v3 GoAll versions3.7.1
Linux distribution packages (35)
git-lfs AlmaLinux:10All versions3.6.1-4.el10_1
git-lfs AlmaLinux:8All versions3.4.1-6.el8_10
git-lfs AlmaLinux:9All versions3.6.1-4.el9_7
git-lfs Red Hat:enterprise_linux:10.1All versions0:3.6.1-4.el10_1
git-lfs-debuginfo Red Hat:enterprise_linux:10.1All versions0:3.6.1-4.el10_1
git-lfs-debugsource Red Hat:enterprise_linux:10.1All versions0:3.6.1-4.el10_1
git-lfs Red Hat:enterprise_linux:8::appstreamAll versions0:3.4.1-6.el8_10
git-lfs-debuginfo Red Hat:enterprise_linux:8::appstreamAll versions0:3.4.1-6.el8_10
git-lfs-debugsource Red Hat:enterprise_linux:8::appstreamAll versions0:3.4.1-6.el8_10
git-lfs Red Hat:enterprise_linux:9::appstreamAll versions0:3.6.1-4.el9_7
git-lfs-debuginfo Red Hat:enterprise_linux:9::appstreamAll versions0:3.6.1-4.el9_7
git-lfs-debugsource Red Hat:enterprise_linux:9::appstreamAll versions0:3.6.1-4.el9_7
git-lfs Red Hat:enterprise_linux_eus:10.0All versions0:3.6.1-2.el10_0.1
git-lfs-debuginfo Red Hat:enterprise_linux_eus:10.0All versions0:3.6.1-2.el10_0.1
git-lfs-debugsource Red Hat:enterprise_linux_eus:10.0All versions0:3.6.1-2.el10_0.1
git-lfs Red Hat:rhel_aus:8.4::appstreamAll versions0:2.13.3-3.el8_4.3
git-lfs-debuginfo Red Hat:rhel_aus:8.4::appstreamAll versions0:2.13.3-3.el8_4.3
git-lfs-debugsource Red Hat:rhel_aus:8.4::appstreamAll versions0:2.13.3-3.el8_4.3
git-lfs Red Hat:rhel_aus:8.6::appstreamAll versions0:2.13.3-3.el8_6.5
git-lfs-debuginfo Red Hat:rhel_aus:8.6::appstreamAll versions0:2.13.3-3.el8_6.5
git-lfs-debugsource Red Hat:rhel_aus:8.6::appstreamAll versions0:2.13.3-3.el8_6.5
git-lfs Red Hat:rhel_e4s:8.6::appstreamAll versions0:2.13.3-3.el8_6.5
git-lfs-debuginfo Red Hat:rhel_e4s:8.6::appstreamAll versions0:2.13.3-3.el8_6.5
git-lfs-debugsource Red Hat:rhel_e4s:8.6::appstreamAll versions0:2.13.3-3.el8_6.5
git-lfs Red Hat:rhel_e4s:8.8::appstreamAll versions0:3.2.0-2.el8_8.5
git-lfs-debuginfo Red Hat:rhel_e4s:8.8::appstreamAll versions0:3.2.0-2.el8_8.5
git-lfs-debugsource Red Hat:rhel_e4s:8.8::appstreamAll versions0:3.2.0-2.el8_8.5
git-lfs Red Hat:rhel_e4s:9.0::appstreamAll versions0:2.13.3-5.el9_0.5
git-lfs-debuginfo Red Hat:rhel_e4s:9.0::appstreamAll versions0:2.13.3-5.el9_0.5
git-lfs-debugsource Red Hat:rhel_e4s:9.0::appstreamAll versions0:2.13.3-5.el9_0.5
git-lfs Red Hat:rhel_e4s:9.2::appstreamAll versions0:3.2.0-2.el9_2.4
git-lfs-debuginfo Red Hat:rhel_e4s:9.2::appstreamAll versions0:3.2.0-2.el9_2.4
git-lfs-debugsource Red Hat:rhel_e4s:9.2::appstreamAll versions0:3.2.0-2.el9_2.4
git-lfs Red Hat:rhel_eus:9.4::appstreamAll versions0:3.4.1-4.el9_4.3
git-lfs-debuginfo Red Hat:rhel_eus:9.4::appstreamAll versions0:3.4.1-4.el9_4.3

How do I fix CVE-2025-26625?

Upgrade github.com/git-lfs/git-lfs to 3.7.1 or later.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2025-26625 being exploited?

There is no known exploitation of CVE-2025-26625 in the wild and no public exploit code.

Sources

Also known as ALSA-2025:23667, ALSA-2025:23744, ALSA-2025:23745, BIT-git-lfs-2025-26625, CLSA-2025-1767003835, DEBIAN-CVE-2025-26625 and 21 more.

Is CVE-2025-26625 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free