When fetching objects from a malicious repository, Git LFS may execute an arbitrary command or binary after incorrectly parsing the Git configuration options defined for a submodule.
Git LFS reads Git configuration options without checking for embedded line-ending control characters. By inserting control characters such as line feed (LF) into certain values, an attacker may be able to mimic options that cause Git LFS to execute an arbitrary command when fetching or adding objects.
Git LFS has resolved this issue by always using an unambiguous format to read and parse Git configuration options.
This problem exists in all versions since 0.6.0 and is patched in v3.8.1. All users should upgrade to v3.8.1.
To work around the problem, users should prevent Git from initializing any submodules by disabling the fetch.recurseSubmodules and submodule.recurse configuration options and by never running the git submodule init command. Any submodules which have already been initialized in a repository may be deactivated with the git submodule deinit command.
If you have any questions or comments about this advisory:
{
"cwe_ids": [
"CWE-144"
],
"github_reviewed": true,
"github_reviewed_at": "2026-11-20T14:58:53Z",
"nvd_published_at": "2026-11-19T17:17:52Z",
"severity": "HIGH"
}